tags:

views:

54

answers:

3

if i have markup like

<nav>
  <ul>
    <li> ... </li>
    <li> ... </li>
    <li> ... </li>
  </ul>
<nav>

and i want to center the nav (either <nav> or <ul> or whatever is appropriate is ok with me). FYI: this for horizontal pagination, so <li> and <a> are floated left

how can i do it?

+2  A: 

See:

Centre widthless floats

Sarfraz
A: 

You can use display: inline-block instead of floats, but beware IE7.

Andrew Vit
+1  A: 

oh i found the answer http://24ways.org/2005/centered-tabs-with-css

jiewmeng
Bingo! +1 from me
Jonny Haynes