View Full Version : The Case Of The Disappearing [And Reappearing] Menu


username132
10-14-2005, 03:49 PM
Success is on the horizon. I don't know how it stands in terms of standards compliance, but I decided to throw in the towel and use <!-- [if IE]> <[end if]--> to enable me to specify a separate CSS file just for loveable old IE.
I just have a few smallish problems left, including the strange case of the disappearing menu... in IE, when I first arrive at my page, the submenu isn't there. If I click on the JCR link at the top, maybe it will appear, maybe it wont. I keep trying. When it does appear, continuing to click might make it disappear again, and so on, seemingly without rhyme or reason.

http://username132.tasminslair.com/website/pages/jcr.php

hobokenjam
10-15-2005, 09:10 AM
I see a major problem with the way you've added your stylesheet links. I haven't taken a look at the specific issue with the CSS, but I'll try and provide comments for that later.

Your page shows:

<link href="../stylesheets/all.css" rel="stylesheet" type="text/css" media="all" />
<!--[if IE]>
<link href="../stylesheets/iespecific.css" rel="stylesheet" type="text/css" />
<![endif]-->
<link href="../stylesheets/print.css" rel="stylesheet" type="text/css" media="print" />

You need to put the stylesheet for printing above all of the other stylesheet links. The order in which differing stylesheets are listed is critical because of the cascading nature of CSS. The rule with CSS is: 'last one in wins'. This means that where there is a conflict between styles, the last style listed is used. It's for this reason that you can override a style set in a linked stylesheet or set in style tags in the head of your document with an inline style.

username132
10-15-2005, 02:57 PM
I don't understand. Surely if the media type is specified as "print", then that stylesheet will be ignored when it comes to rendering the webpages on screen.

username132
10-15-2005, 06:02 PM
Also, since the iespecific.css file specifies that the secondary_nav and tertiary_nav are to float: left, and also that the footer is to clear: both, shouldn't the situation [footer crashes into menu] seen at http://username132.tasminslair.com/website/pages/jcr_officers.php be avoided?