Internet Explorer makes me sad every time I open it to cross-browser test during development and it crashes on
console.log. A simple check OR define option can kill console in the IE developer toolbar, so I decided to write a more robust cross-browser compatible
There are a few Sass media query mixins going around for dealing with old versions of IE. Often they include predefined break points, whereas I like the simplicity of passing a numeric value.
Capable browsers wrap the content in a media query, incapable browsers get the unwrapped content.
The HTML5 Boilerplate popularised the html tag conditional classes pattern. This pattern is usually some variation of:
<!--[if lt IE 7 ]> <html lang="en" class="ie6"> <![endif]-->
<!--[if IE 7 ]> <html lang="en" class="ie7"> <![endif]-->
<!--[if IE 8 ]> <html lang="en" class="ie8"> <![endif]-->
<!--[if IE 9 ]> <html lang="en" class="ie9"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!--> <html lang="en"> <!--<![endif]-->
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
We recently changed the way we do IE hacks at Soupgiant. For years we used conditional comments to load separate CSS files.
For a few sites, we used Paul Irish’s conditional HTML classes hacks. Without workarounds, this puts IE in compatibility mode.
I think, much of the time, when website owners and developers decide to drop support for IE6, we go about it the wrong way.
For a not-for-profit, like WordPress.org, the decision can be simple. The project is free and the cost is resources. To no longer support IE6 in their admin means the WordPress team can develop more efficiently. When a website makes a profit, however, I think the decision is black and white.
Increasingly I’m reading of web developers deciding to drop IE6 from their list of supported browsers, usually, because of its creative interpretation of CSS standards, besides IE7 is over a year old, and, IE8 about to be released.
I’ve decided to continue support for IE6 as it’s still in wide use – especially in corporate environments – and, I don’t think it needs to take a lot of work to develop for. I’ll say that again, I don’t think IE6 is as bad it’s sometimes made out to be.