Posted By

Japegrape on 06/27/14


Tagged

ie html conditional comments


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

Japegrape
jakkrith


HTML Tag IE Conditional Comments


 / Published in: HTML
 

Code to replace your opening tag with conditionally set IE classes, including IE10.

  1. <!DOCTYPE html>
  2. <!--[if lt IE 7]> <html class="no-js lt-ie10 lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
  3. <!--[if IE 7]> <html class="no-js lt-ie10 lt-ie9 lt-ie8 ie7"> <![endif]-->
  4. <!--[if IE 8]> <html class="no-js lt-ie10 lt-ie9 ie8"> <![endif]-->
  5. <!--[if IE 9]> <html class="no-js lt-ie10 ie9"> <![endif]-->
  6. <!--[if gt IE 9]><!--> <html class="no-js"> <!--<![endif]-->
  7. <!--[if !IE]><!-->
  8. if( Function('/*@cc_on return [email protected]*/')() ) {
  9. document.documentElement.className+=' ie10';
  10. }
  11. </script>
  12. <!--<![endif]-->

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: hardwork23 on July 10, 2018

If you need to have help and support while taking system backup windows 10 so this portal will be the exact and finest option for you to solve your all hurdles. As we all know that solution to every problem can be found out online only if you are on the right path.

Posted By: charmi89 on September 25, 2019

Conditional comments are a sort of instructions only meant for IE and it is ... It is similar to HTML comment and so other browsers treat it as a comment and IE can ... Then in your page.tpl.php file, add the following piece of code inside tag. https://customerfeedbacks.info/

Posted By: jhonsmith858585 on December 6, 2019

Thanks For Sharing With Us Amazing Guide

Survey

You need to login to post a comment.