The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS IE hack

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #38260

    Hi Everyone,
    I have a problem about css hack, when the browser is IE 7, I just want add some simple css style to the website ( just like the What should I do ?


    What if there are some defined styles I don’t want to put to IE ?
    I have to reset all these defined styles ?


    The idea is that you create a main stylesheet that works for the vast majority of browsers.

    If you have specific tweaks to make to get your site to work or look the same in IE you only write those styles in the IE sheet.

    You link to the IE sheet AFTER the main one and the cascade will overwrite the CSS styles that will only be affected for IE.

    However, in the unlikely event that you have a style on your main sheet that you don’t want in IE (and I can’t think of one off hand), the “Yes”, you would have to alter it in your IE sheet.


    If you are using something like HTML5 Boilerplate + Modernizer, you can target IE by using the classes placed on the < head> tag.

    Eg: .lt-ie8

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.