[Add to favorites] CSS or Javascript for different versions of IE Web browsers

Source: Internet
Author: User

Usage:

 
<! -- [If lt IE 8]>Code here<![Endif]-->

The explain statement is as follows:

    • GT = selects greater than (higher)
    • Lt = selects less than (lower)
    • GTE = selects greater than or equal to (> =)
    • LTE = selects less than or equal to (<=)
    • ! = Selects everything failed t what directly follows "! "(Select all, !)

Practical application:

  • Select ie5.01 to use "<! -- [If Internet Explorer 5.0]>"
    Or "<! -- [If ite Internet Explorer 5.0]>"
    Or "<! -- [If! Gt ie 5.0]>"
    Or "<! -- [If lt Internet Explorer 5.0000]>"
    Or "<! -- [If! GTE ie 5.5000]>"
  • Select ie5.5, ie6.0, and ie7.0. You can use "<! -- [If! Internet Explorer 5.0]>"
    Or "<! -- [If gt ie 5.0]>"
    Or "<! -- [If! Lte ie 5.0]>"
    Or "<! -- [If! Lt Internet Explorer 5.5000]>"
    Or "<! -- [If GTE ie 5.5000]>"
  • Select ie5.5. You can use "<! -- [If Internet Explorer 5.5000]>"
  • Select IE 5.01, IE6, and ie7.0. You can use "<! -- [If! Internet Explorer 5.5000]>"
  • Select IE 6. You can use "<! -- [If IE 6]>"
  • Select IE 5.01, ie5.5, and ie7.0. You can use "<! -- [If! IE 6]>"
  • Select ie 7.0. You can use "<! -- [If Internet Explorer 7.0]>"
    Or "<! -- [If! Lte ie 6]>"
    Or "<! -- [If gt ie 6]>"
    Or "<! -- [If! Lt Internet Explorer 7.0]>"
    Or "<! -- [If GTE ie 7.0]>"
    Or "<! -- [If! Lt IE 7]>"
    Or "<! -- [If IE 7]>"
    Or "<! -- [If gte ie 7]>"
  • Select IE 5.01, ie5.5, and IE6. You can use "<! -- [If lte ie 6]>"
    Or "<! -- [If! Gt ie 6]>"
    Or "<! -- [If lt Internet Explorer 7.0]>"
    Or "<! -- [If! GTE ie 7.0]>"
    Or "<! -- [If lt IE 7]>"
    Or "<! -- [If! Gte ie 7]>"
    Or <! -- [If! Internet Explorer 7.0]>"
    Or "<! -- [If! IE 7]>"
  • Select IE 5.01 and ie5.5. You can use "<! -- [If IE 5]>"
    Or "<! -- [If LTE ie 5]>"
    Or "<! -- [If! GT ie 5]>"
    Or "<! -- [If LTE ie 5.5000]>"
    Or "<! -- [If! GT ie 5.5000]>"
    Or "<! -- [If lt IE 6]>"
    Or "<! -- [If! Gte ie 6]>"
  • Select IE 6 and ie7.0. You can use "<! -- [If! IE 5]>"
    Or "<! -- [If! LTE ie 5]>"
    Or "<! -- [If GT ie 5]>"
    Or "<! -- [If! LTE ie 5.5000]>"
    Or "<! -- [If GT ie 5.5000]>"
    Or "<! -- [If! Lt IE 6]>"
    Or "<! -- [If gte ie 6]>"
  • Select IE 5.01, ie5.5, IE6, and ie7.0, and use "<! -- [If LTE ie 7.0]>"
    Or "<! -- [If GTE ie 5]>"
    Or "<! -- [If gte ie 5.0]>"
    Or "<! -- [If lte ie 7]>"
    Or "<! -- [If IE]>"
  • No Internet Explorer 5.01 or Internet Explorer 6
  • No IE 5.01 or ie7.0
  • No Internet Explorer 5.5 or Internet Explorer 6
  • No IE 5.5 or ie7.0
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.