Friday, 19 November 2004
I’ve received a number of questions about the way I promote Firefox on this website. IE users see a large red bar on top of every page that will basically tell them to get Firefox. Most questions were about the way I show this red bar… Well thanks to Microsoft, it is actually very simple. Oh, the irony.
IE supports something that is called conditional comments. They are basically an extension to the regular comments that are defined by the (X)HTML standards. Sounds complicated, but it really isn’t. The guys at Redmond even wrote very helpful tutorial about it.
In case you are wondering how my website looks like in IE, and what I am talking about, take a look at this screenshot:
This is what the code on my website looks like:
<!--[if IE]> <div class='message'> <h1>It appears you are using the Internet Explorer web browser...</h1> <p> <a href='http://www.spreadfirefox.com/community/?q=affiliates&id=3571&t=54'> <img src='http://www.rakaz.nl/nucleus/skins/rakaz/get.gif' alt='Get Firefox!' /> </a> This site relies heavily on web standards and unfortunatly Internet Explorer does not yet fully support web standards. Therefore your browser may not display this website correctly. We recommend that you download and try out a standards compliant browser such as Mozilla Firefox. </p> </div> <![endif]-->
Everything between the
--> will be hidden from the browser, because the HTML standard defines this as a non-visual comment. IE however, recognized the
[if IE] part after the