The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Centering a nav element in a div. Re: Centering a nav element in a div.


Just having a look at that, I think your problem might be related to using float: left on nav ul. nav ul is the container of all of the nav links, so floating that to left with take the whole menu to the left.

I would try display: block; margin: 0 auto; on the nav ul element. From what I can see, that would centre the nav.