Gavin W Gavin W - 2 years ago 114
HTML Question

Center NavBar content/links

I need to center the content-links in my navbar. This:
enter image description here

I want the Home, About and Contact to be centered on the navbar.

Answer Source

Instead of using float, you can set the li element to display: inline-block and add text-align: center on the ul element.

ul {
    text-align: center;
li {
    display: inline-block


Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download