IE6 Woes and hasLayout

IE6PITA – The Back Story
As anyone who has spent any amount of time making website will tell you, Microsoft Internet Explorer 6 (IE6) is a pain in the arse. When it was first released in August 2001 it seemed like quite a good piece of software and it was, to a certain extent. At the time IE5 had already surpassed Netscape as the most popular web browser and version 6 improved on that, introducing support for various TLAs. In fact IE6 was arguably too good, or at least too well marketed… IE6 was released at a time when a lot of companies were starting to use the internet. Some of these companies commissioned other companies to custom-build programs, websites and IE plugins (well, Active-X plugins. Whatever…) for them.

Why We’re Stuck With It
Some of these programs/plugins/website/intranets were made in such a way that they would only work in IE6. And some of these became deeply ingrained in the company’s way of working. And in some cases the people in charge of the software found it was cheaper or easier to just carry on using IE6 than it was to upgrade (and re-train people to use the new versions, and upgrade the hardware to support new software etc.). And so we find a lot of companies around the world who have hundreds (even thousands) of employees using a 9-year-old, outdated, insecure browser because it’s the only piece of software they can use to get the job done.

So it’s an awkward situation. On the one hand it would be better for everyone if everyone upgraded (better for the users – they’d get a better browser; better for web designers – the standards they follow would have more meaning and they wouldn’t have to write everything twice; better for everyone else – because IE6 is insecure a dodgy web-page can infect a computer which can then, for example, send out spam or infect other computers). But on the other hand, you can’t force all these businesses to upgrade, even if they want to – the cost is often prohibitive. Even if they can afford to upgrade one system, this might have a knock-on effect – they might then have to upgrade another system etc.

Yeah? And?
At this point you might ask four important questions: “Yeah? And? So? What?” Sure, businesses are stuck with it and it’s not very secure but why would a web designer care? Because, as I mentioned above, it’s a pain in the frickin arse.

HTML is (roughly speaking) the language that the WWW runs on. This web-page was made as an HTML file by the server, sent to you as HTML. Your web browser then looked through the information in the HTML, interpreted it in it’s own special way and then showed you the result. (There’s also some CSS which tells your browser how to style the content and some JavaScript which tells the browser how to react to certain interactions). Unfortunately Microsoft and others didn’t agree on the way things should work.

Standards
The standards on which the world wide web are based are developed by the W3C, the World Wide Web Consortium, a group headed by Mr Internet himself, Sir Tim Burner-Lee – the man who invented the WWW. For example the HTML standard (Currently on version 4.01, version 5 is in the works but, unsurprisingly, they’re having trouble agreeing) defines how a web browser should deal with HTML. However, because of the way that the internet works the W3C standards are basically well-thought-out suggestions. Each browser is free to interpret HTML in any way it likes and no-one could stop it.

An Analogy
Maybe it will help to think of it in terms of natural language. Let’s say I only speak English. HTML is French. My web browser is an interpreter. The website that I am looking at speaks grammatically perfect French. So, if I was visiting the site using a standards-compliant browser (interpreter) (Mozilla Firefox would be a popular choice for this title) I would be presented with an identical copy of the the site but in English. All the same, with similes and metaphors intact but in English. Brilliant!

Now I look at the same site with IE6. IE6 isn’t a perfect interpreter. It’s OK, I mean, most of the time you’ll get the gist but some of the subtlety and flair will be lost in the translation. And it uses slang which it made up itself! Sure, the slang works great when the both parties understand it but it’s kind of like translating Descartes and “The first precept was never to accept a thing as true until I knew it as such without a single doubt. ” becoming “The cake is a lie.” Sure, the meaning is still there (sort of) but not everyone gets it.

Ok, Enough Of That Analogy
Worse still is the differences in layouts that IE will give compared to standards-based browsers. To stretch an analogy a little too far “I think; therefore I am” becomes “I am; therefore I think”. Everything’s still there, so what’s the problem?

What The Hell Was I Talking About?
Aaaaanyway. I came here to write about IEs “hasLayout” property and how crap it is but I got distracted by why it’s so crap. It’s almost time to go home, so I’d better start typing quicker… Back in the day everything on a webpage was a box – a rectangle. Pretty quickly it became obvious that this was limiting. So the geniuses at Microsoft introduced the hasLayout property. You can read about it here.

Summary
So to summarise the article that I would have written if I hadn’t gone off on one and which is, therefore, not actually this article but one that hasn’t even been written… To summarise the article that I’ve linked to: hasLayout is the cause of most of IE6s layout bugs. If you’re having trouble with layouts in IE6, go read about hasLayout, it might help.

Unfortunately it’s not the cause of the bug I am currently trying to get rid of. For fucks sake…

[Edit: I’ve just realised that the post before this says to expect some anti-IE6 rants…I was not wrong.]

Advertisements

About Mr Chimp

I make music, draw pictures, browse the internet, programme, and make sweet, sweet cups of tea until the early hours.
This entry was posted in Uncategorized and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s