cssinternet-explorerquirks-mode

What is the quirksmode code for loading styles based on IE version


What is the syntax if I want to load a css file in my website with if statement.

Situation is like this.

If ie6 I will load ie6_style.css

and if ie7, mozilla, or new browsers, I will load style.css


Solution

  • <link rel="stylesheet" type="text/css" href="style.css">
    <!--[if IE 6]>
    <link rel="stylesheet" type="text/css" href="ie6_style.css">
    <![endif]-->