Hello everyone, do you think it's worth it to make a separate css file for each browser version ie? or is it enough to single out some particular version of ie? And how about 10 version ie, which does not respond to the comment <! - [if IE 10]> <! [Endif] ->

  • Do you use any ready-made framework? - intertex

5 answers 5

  1. No, IMHO, not worth it. Still, there are not so many things that IE (starting from, probably 9, I don’t remember about 8) does not support.
  2. Use the css hack:

    @media screen and (min-width: 0 \ 0) {/ your css /}

  • Offtop . Damn, well, when already for the donkey will not need any hacks? Already about the ninth version we begin to forget, and this "miracle" is still crooked. @ Max Zhukov, I am not in your stone garden! [Alt text] [1] [1]: i.imgur.com/iZ7fP9z.gif - Deonis

And why it is impossible to use modernizr for those styles that ie (and other browsers) do not support?

    for 10 and 11 versions it connects like this

    <! [if IE]> You use IE <! [endif]>

    • As for all other browsers. - Qwertiy

    Support for conditional comments in standard mode and compatibility mode Internet Explorer 10 has been removed to improve interoperability and compatibility with HTML5. This means that conditional comments are now treated like regular comments, just like in other browsers.

    A page using conditional comments works fine in Windows Internet Explorer 9 , but does not work in Internet Explorer 10 .

    If this page works fine in other browsers, try using feature detection to interact with Internet Explorer 10 , as well as with other browsers. Or add to the top of the page the following meta tag, which determines the choice of Internet Explorer 9 behavior:

    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE9"> Примерно так: <html> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE9"> <!--[if IE]> This content is ignored in Internet Explorer 10 and other browsers. In older versions of Internet Explorer, it renders as part of the page. <![endif]--> </html> 

    Now at the expense of hacks:

     @media screen and (min-width:0\0) { /* стили только для IE9 - IE10 */ } @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { /* стили только для IE10 */ } 
    • <meta http-equiv = "X-UA-Compatible" content = "IE = EmulateIE9"> is not very good advice. - ferrari
    • This is an option - but this is not the rule. My opinion is to use as little hacks as possible or to strive for it - soledar10

    Excellent article on this topic: https://www.kobzarev.com/makeup/ie10-css-hacks/

    My favorite hack:

     @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { /* стили только для IE10 и 11 */ }