Don’t write off Internet Explorer just yet (and how to make sure your website renders correctly with Internet Explorer 8)

This content is 16 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

Microsoft Windows Internet Explorer 8 logoI’ve had a few communications from Microsoft this week attempting to hammer home the point that Internet Explorer (IE) 8 was released last week. My personal view is that many technical users switched to alternative browsers during the time when “Internet Exploder” was, frankly, not that great (a deliberate understatement) and that it will take a long time for them to return (if, indeed, they ever do); however the majority of consumers and enterprises are still using IE for two reasons:

  • It ships with Windows.
  • They see no need to upgrade/switch browsers (unless Windows Update does it for them).

There are of course those who will highlight IE’s problems (for example, that it accounts for a significant number of the security updates produced for Windows) but, in fairness, competing products have similar issues and in some ways I’d rather be running a popular browser that others will find the holes in and the vendor will (hopefully) fix (of course, the same argument is often levied as a reason to run open source applications).

I would like to point out though that Internet Explorer 8 is a huge step forward for Microsoft – both in terms of standards compliance and when looking at its feature set and these days I rarely run anything other than a native browser (IE on Windows, Safari on Mac) because the return of the browser wars has really helped operating systems to raise their game when it comes to browser functionality. IE8 works for me – and whilst there may be tons of add-ins for Firefox, it’s those add-ins that can make the browser unstable too. Similarly, Google Chrome is great for running Google Apps as though they were desktop applications but I fall back to IE when a website fails to render in an alternative browser. And Opera (one of the competitors currently winding up the European Union to drag Microsoft through the courts again in a battle which does little-or-nothing for end users and costs us all a load of money) – they are little more than a distraction, as can be seen in my webstats for March:

Browser Percentage of traffic
Microsoft Internet Explorer 47.26%
Mozilla Firefox 39.24%
Apple Safari 6.33%
Google Chrome 3.91%
Opera 1.90%

If I look at the IE versions in use though, almost 70% are on IE7, around 10% are on IE8, and 21% of my IE visitors (so around 10% of my overall traffic) are still running IE6. My stats are probably skewed due to the number of technical readers (who often run the latest and greatest or the more obscure technologies) but it seems that IE6 is finally becoming a minority browser (and I had just 9 visits from other versions of IE last month).

It seems to me that, for most web developers, there really is little reason not to adhere to web standards and those IE hacks to sort out transparent PNGs, rendering issues and a miscellany of other “quirks” will soon become a thing of the past. Even so, there are still a significant volume of users running older browsers, so we can’t cut loose entirely (IE6 users accounted for over 12% of this site’s revenue last month… that might not be a lot of money but there is a saying that “if you look after the pennies, the pounds will look after themselves“) and, if redeveloping your site to tell it not to run loads of IE hacks is too big a project (or if you still want to direct IE8 to view your site in a particular manner), I saw a document today that details the metatags that can be used:

Internet Explorer 8 ships with multiple rendering modes that may be set by using the X-UA-Compatible header. Web developers can use the ‘meta tag’ to instruct Internet Explorer 8 to render content using a specific mode – to ensure legacy code and applications work properly. The ‘meta tag’ can be included as an HTTP response header for a server-wide solution or on a page by page basis. At the page level instructing the browser to render using the IE7 mode, the ‘meta tag’ would look like:

<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" >

More than just IE7 mode
The following chart lists the available modes and values for the ‘meta tag’:

Compatibility Mode Value Render Behavior
IE=5 “Quirks” mode
IE=7 Internet Explorer 7 Strict mode
IE=EmulateIE7 Use the !DOCTYPE declaration to determine mode:

  • Quirks mode !DOCTYPEs result in Quirks mode
  • Standards mode !DOCTYPEs result in Internet Explorer 7 Strict mode
IE=8 Internet Explorer 8 Standards mode
IE=EmulateIE8 Use the !DOCTYPE declaration to determine mode:

  • Quirks mode !DOCTYPEs result in Quirks mode
  • Standards mode !DOCTYPEs result in Internet Explorer 8 Standards mode
IE=edge Uses latest standards that Internet Explorer 8 and any future versions of the browser support. Not recommended for production sites.

Browser competition is great news – if it hadn’t been for Firefox, Microsoft would not have kick-started Internet Explorer development – but I think that, for the majority of users, Internet Explorer 8 is worth a look. Meanwhile, for many web developers with sites that don’t render correctly in IE8 (like mine!) the chances are that a single line of code in the <head> section of your (X)HTML will fix it – you can find out more (including fully-functioning demonstrations and code samples) at the IE8 developer demonstration website.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.