Posted By

DenoteIt on 08/09/11


Tagged

ie


Versions (?)

HTML Conditional Comments


 / Published in: HTML
 

HTML conditional comments used to target specific versions of Internet Explorer (is ignored by all other browsers).

  1. <!-- Condtional comment: All IE Versions -->
  2. <!--[if IE]>
  3. This is Ineternet Explorer
  4. <![endif]-->
  5.  
  6.  
  7. <!-- Condtional comment: IE6 only -->
  8. <!--[if IE 6]>
  9. This is Internet Explorer 6
  10. <![endif]-->
  11.  
  12.  
  13. <!-- Condtional comment: All IE versions after 5 -->
  14. <!--[if gt IE 5]>
  15. This Internet Explorer was released after IE5
  16. <![endif]-->
  17.  
  18.  
  19. <!-- Condtional comment: All IE versions before 8 -->
  20. <!--[if lt IE 5]>
  21. This Internet Explorer was released before IE8
  22. <![endif]-->

Report this snippet  

You need to login to post a comment.