Horizontal Navigation CSS Difference between Firefox 3.6 and Firefox 4
In FF4, the "Contact Us" link appears under my "Home" link in the horizontal navigation at the top of the page at www. avaline .com (and on all pages under that domain). In FF 3.6 it looks fine and fits within the 900px width ul element.
What am I missing to get this to work better across browsers?
<ul id="nav2">
<li><a href="/" title="promotional products home">home</a></li>
<li><a href="/Information/Product-Testing-Library" title="product safety">product safety</a></li>
<li><a href="/Current_Specials?loc=top" title="current promotional product specials">current specials</a></li>
<li><a href="/Marketing-Tools/2011-Digital-Catalog-and-Request-Form" title="digital and request catalog">request catalog</a></li>
<li><a href="/Marketing-Tools?loc=top" title="marketing tools">marketing tools</a></li>
<li><a href="/Informati开发者_开发知识库on/About-Us" title="about us and our promotional products">about us</a></li>
<li><a href="/Contact-Us" title="Contact us about our promotional products">contact us</a></li>
</ul>
#header_top ul#nav2 {
margin: 0;
padding: 0;
list-style: none;
position: absolute;
top: 79px; /* was 80px ll */
width: 900px; /* was 776 ll */
left: 7px; /* was 64px */
font-family: Arial, Helvetica, sans-serif;
}
#header_top ul#nav2 li {
float: left;
font-weight: bold;
padding: 0 23px;
font-size: 11px;
list-style:none;
}
#header_top ul#nav2 li a {
color: #fff;
text-transform: uppercase;
}
#nav3 a, #nav3 a a:link, #nav3 a a:visited, #nav2 li a, #nav2 a a:link, #nav2 li a a:visited, #nav1 li a, #nav1 a a:link, #nav1 li a a:visited {text-decoration: none;}
#nav3 a:hover, #nav3 a:active, #nav2 li a:hover, #nav2 li a:active, #nav1 li a:hover, #nav1 li a:active {text-decoration:underline;} /* ll */
It appears fine on my Firefox (v 4.0.1) running on Windows7 x64 Home Premium
I could, however, reproduce your 'bug' in IE9, however this was easily fixed by changing the padding of the li element to 21px ( instead of 23px ).
jsFiddle: http://jsfiddle.net/KBgKa/5/
精彩评论