Meri wrote:
Everybody on the internet
Tell them hello for me.
seems to think this is a problem with IE but for
me it works fine with IE, but the submenus do not appear with Firefox
andOpera.
The html is a simple list with sublists.
The CSS looks like this:
Oh, a URL to a simplified test case is always so much better.
>
#menu ul {
list-style: none;
margin: 0;
padding: 0;
display: block;
font: bold 14pt/14pt "Times New Roman";
You should probably get rid of the /14pt here, since you presumably want
a standard line-height. Second-best is to replace the pt-units-based
value with a value without units, such as 1.2 or 1.3.
See <http://www.w3.org/TR/CSS21/visudet.html#propdef-line-heightfor
usage of "number" values, plus search the Web/Usenet for further
discussions on why and when to use such values.
Also, 14pt is a specification best used for printing. Better is a
percentage, like 100%. See <http://tekrider.net/html/fontsize.php>.
Furthermore, what happens to the visitors who don't have Times New
Roman? Do you want them to see their default serif font? Or just their
default, which might be sans-serif, like Arial or Helvetica? Consider
adding a generic family, such as
font: bold 100% "Times New Roman",serif;
line-height: 30px;
What?!? Why did you have the /14pt then?
And what happens when the visitor upsizes the text? Yes, the txt grows
out out of the space you've provided it.
width: 200px;
Same here. Try something in em units.
}
So we show the main menu. But we don't show the submenus:
#menu ul ul {
list-style: none;
margin: 0;
padding: 0;
display: none;
font: bold 12pt/12pt "Times New Roman";
line-height: 30px;
position: absolute;
left: 200px; top: 0px;
}
Except when the mouse is over the list item:
#menu li:hover ul {
display: block;
}
Here's why a URL is better: why could try it ourselves if we had a URL.
>
This works beautifully with IE (version 7.0.5730.11) but the submenus stay
hidden with Firefox (version 2.0.0.14) and Opera (version 9.10).
As it will in IE6 (and under), since :hover isn't supported on elements
other than <ain IE6.
I suspect there is some problem with the code and/or your selectors,
keeping #menu ul ul from being the same as #menu li:hover ul. Otherwise,
I'm wondering about a sub-menu item that appears in an
absolutely-positioned location. Are you sure it's not appearing, but is
just *behind* something else?
I have
Windows XP Home if it makes a difference. I've tried different combinates of
li ul and li:hover :-) I even tried a:hover but then it doesn't work with IE
either.
I define colors under #menu a, #menu a:hover etc.
Could be. URL?
--
John
Pondering the value of the UIP:
http://improve-usenet.org/