Posted By

amyb on 03/30/11


Tagged

css ie


Versions (?)

Show different stylesheets for different versions of IE


 / Published in: HTML
 

Add to the of your page after the main stylesheet to serve different stylesheets for different versions of Internet Explorer

  1. //for any version of IE
  2.  
  3. <!--[if IE ]>
  4. <link rel="stylesheet" href="file_path/ie.css" type="text/css" />
  5. <![endif]-->
  6.  
  7. //For IE 6 or earlier
  8.  
  9. <!--[if lte IE 6]>
  10. <link rel="stylesheet" href="file_path/ie6.css" type="text/css" />
  11. <![endif]-->
  12.  
  13.  
  14. <!--[if IE 7 ]>
  15. <link rel="stylesheet" href="file_path/ie7.css" type="text/css" />
  16. <![endif]-->

Report this snippet  

You need to login to post a comment.