IE5 and IE5.5 compatibility
conditional comments
A few modifications are necessary to improve the menu1 with IE 5 and IE 5.5:
We still need two stylesheets:
pagecss2nn4.css with the rules that are ignored or correctly interpreted.
pagecss2.css with the new rules and what generates display problems.
We will add a few conditional comments instead of hacks.
<link rel="stylesheet" href="pagecss2nn4.css" type="text/css" /> <style type="text/css"> <!-- /*<![CDATA[*/ /*is ignored by nn4 or ie4*/ @import "pagecss2.css";/*overwrites previously defined styles*/ /*to add here or in pagecss2nn4*/ #menugauche li{ margin-top:0; border-top:1px solid #90BADE; margin-bottom:-1px; } /*]]>*/ --> </style> for any version before MSIE 5.5 <!--[if lt IE 5.5]> <style type="text/css"> #menugauche li{ border-bottom:0; margin-bottom:-5px; } </style> <![endif]--> for MSIE 5 and 5.5 - menu width <!--[if lt IE 6]> <style type="text/css"> #menugauche li a{ width:155px; } </style> <![endif]-->
There will be no change for other browsers.
Left
Center
Right
The text is hidden
if there is
an overflow
so that alignment
is not modified.
Wide column on the left
Narrow on the right
Centered text
Bold characters
Only CSS, no table and no javascript.
The number of MSIE 5 and MSIE5.5 users is decreasing, but it is high enough to test your pages.
1 CSS cutting edge proposes other cross-browser solutions without lists for vertical and horizontal menus.
1 Other solutions for horizontal and vertical menus.