Dónal
Dónal

Reputation: 187379

"fix internet explorer" stylesheet

I have a website that I've developed and tested using Firefox 9 exclusively. I'm pretty happy with the layout/styles when viewed in this version of Firefox. I'm now facing the unenviable task of making it display equally well (or as close as possible) in IE7+ (I'm not supporting IE6). Naturally, I'd also like it to display well in Chrome & Safari, but I think they implement the standards reasonably well, so I'm not so worried about them.

I'm using JQuery for JavaScript, which hopefully means I don't have too many differences in JavaScript behaviour, so my chief concern is the CSS. I imagine many others have been down this path, so I'm hoping there's a stylesheet available which when (conditionally) included will fix most common CSS problems seen when viewing a website in IE that has only been tested with Firefox. Does such a thing exist?

Upvotes: 3

Views: 7399

Answers (2)

Conan
Conan

Reputation: 2709

A catch-all miracle.css file which cures all IE-related ills? If only! The solution will probably boil down to a selection of some or all of the following:

  • Normalize (http://necolas.github.com/normalize.css/)
    Brings most browser default settings to a more consistent baseline (think of this as an alternative to the popular Eric Meyer reset.css)
  • Modernizr (http://www.modernizr.com)
    Seeing as you're already using javascript, including modernizr will give you additional methods of detecting browser capabilities. Also auto-injects .ie7 / .ie8 etc classes into your markup where necessary, allowing you to target IE in your styling, e.g.
    .standard { ... }
    .ie7 .standard, .ie8 .standard { ... }
  • CSS3PIE (http://www.css3pie.com/)
    Progressive Internet Explorer - allows for styling which typically fails on IE (e.g. linear gradients, radiused corners, etc.)
  • IE7.JS (http://code.google.com/p/ie7-js/)
    Probably the closest to what you were after, as an alternative to CSS fixes (which no doubt will still be necessary). Should help get you closer to the desired end result though.

Upvotes: 6

AKFourSeven
AKFourSeven

Reputation: 1325

I don't think there is any sort of stylesheet that does this for you.

You may look into a js script that look at solving IE issues. Or You can always do it the old fashion way using IETab and targeting the areas where you know there is going to be issues.

Most of them are described here: http://net.tutsplus.com/tutorials/html-css-techniques/9-most-common-ie-bugs-and-how-to-fix-them/. Hope it helps :)

Upvotes: 0

Related Questions