How to add specific style/script for IE in HTML?

There are times when we want a specific style or stylesheet or a javascript to be rendered only in IE and not other browsers such as FireFox. If this is so, then you can do so by adding following if and endif declarations in the HTML. Insert the style or stylesheet or javascript that needs to be rendered only by IE between the if and endif declarations in the HTML.

<!- -[if IE]>

Style or Stylesheet or JavaScript that should be rendered by Internet Explorer (IE) only will come here.

<![endif]- ->

3 thoughts on “How to add specific style/script for IE in HTML?”

  1. I’ve run into several wbsites recently that do not show foreign language title or text if viewed with Mozilla Firefox but come in loud and strong with IE. One particular site was hosted by register.com, but I believe it’s the Firefox browser. waht’s their problem – anybody know?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.