> From: css-d-boun...@lists.css-discuss.org on behalf of AG > Sent: Wed 4/1/2009 4:26 PM > To: css-d@lists.css-discuss.org > Subject: [css-d] center float:left > > Here's the problem: > - building a horizontal tabbed navigation bar with these conditions: > > 1. equal width of tabs > 2. centered to the width of the body > 3. preserve centering when adding/subtracting tabs [dynamically generated > links/tabs] > > All menus based upon the <ul> type of lists use a float:left or right > approach. You can center a list if it's enclosed in a div with a fixed width. > However, as mentioned above, this is not a solution to my problem since the > tabs are dynamically generated. > > The tabs can be centered eliminating the float, but, you loose the equal > width condition. > > Any ideas would be greatly appreciated. Needs to work in IE6 and all normal > browsers.
Did you try something like: UL or enclosing DIV ~ display:inline; margin-left:auto; margin-right:auto; text-align:center; LI's ~ display:inline; white-space:no-wrap; A's ~ display:block; width:###px; ______________________________________________________________________ css-discuss [cs...@lists.css-discuss.org] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ List policies -- http://css-discuss.org/policies.html Supported by evolt.org -- http://www.evolt.org/help_support_evolt/