We've moved!

TechKnack.blogspot.com has officially moved to TechKnack.net. You should be redirected in 3-5 seconds. Thank you.

February 10, 2008

An Alternative to IE8's "Opt-in Standards Mode"?

Add this post to Del.icio.us. Del.icio.us (0 saved)

There's been a lot of opinions expressed about the IE team's introduction of the X-UA-Compatible HTTP header (or, in most cases, a meta tag in the html), otherwise known as Opt-in Standards Mode, with IE8. Most of the opinionators seem to be opposed to the "switch", while a few (PPK of QuirksMode and Aaron Gustafson of AListApart amongst them) have already embraced it. But is there a better way?


Reading through user comments on PPK's post, I came across some interesting ideas. BARTdG said

...I think they should solve this problem by adding a "Does this site look odd?"-button (to switch IE8 into IE7-mode)...

And Michiel van der Blonk said

I see a different scenario possible. MS ships the new IE8 with full forward compatibility mode (edge) as a default, as all standards aware developers expect it. But, they also deploy a 'crippled' version of IE8 that has all the security features and what not but will render using the IE6 engine.

Tino Zijdel:

If the problem lies mainly with IE-centered intranet apps then why doesn't MS offer a special fabriqued 'Intranet Explorer'?

An alternative?

What if standards-compliant rendering were placed in the hands of the users?

I mean, this is pretty much the case now, what with people having a choice (most of the time) between using IE6, IE7, FireFox, Opera, Safari, Konqueror, and more. Those ignorant of their options will use what they're given, IE7 (or IE8 with the default mode). Why not leave whether or not IE8 renders properly as an option for the user to invoke?

Suppose IE8 ships with two rendering engines (which is how it looks anyway): IE7's current engine, and IE8's new engine. IE8 Standards Mode could be the default engine, which perhaps degrades to IE7 Quirks Mode given a lack of Doctype. Then suppose that there is a button (or menu item, or statusbar icon, or etc) which allows the user to switch to back to IE7 rendering mode (Quirks/Standard, depending on doctype presence). What could the implications of this be?

Possible issues

Breaking the web

If IE8 mode is the default engine, then IE8 will, by default, "break the web". However, most people have noted that the main recipients of this breakage will be company intranets. I've never maintained an intranet before, but surely it wouldn't be too difficult to implement a "switch" of some sort that can easily be used to mass-switch the company's IE8 installations to use IE7 mode.

More crossover

A major concern that might arise is that we developers will have to develop for both IE7 mode and IE8 mode, to cater to all users. So, what exactly are we doing now? Well, those aiming for cross-browser compatibility are still developing with an eye on IE6, as well as IE7, FireFox, etc. And, if the Acid2 announcement is any indication, IE8's Standards Mode shouldn't be too difficult to cater to, if the design works in other majorly-standards-compliant browsers. As Hixie puts it (albeit on a slightly different topic):

Finally, we could just... [continue] to use JS compatibility libraries for the time being, the same way that everyone has been doing for years. Authors would also have to support IE7 anyway, at least for the forseeable future, so it wouldn't be an additional cost.

Usability issues

"Oh, noes, more menu options??? You'll confuse the poor user!" Please. My favorite website looked fine in IE7, and now it won't work in IE8. What's this? A button that makes IE8 work like IE7? Cool! *click* Hey, it works now!
Even better, in the case of "mass-switched company-intranet users": My favorite website worked in IE7. I've been upgraded to IE8 which, since its been switched to use IE7's engine, still displays the site as it always has. I'm sooo happy. :D
And, honestly, if someone sees the button that says "Switch to IE7 mode", and has no clue what that means, are they going to melt down in a puddle of confusion? No. They will ignore it. If they are the initiated type, they might click it to see what it does, or go in search of someone or something that can explain it to them.

A better solution?

I believe this might be better than forcing developers to add a meta tag (or HTTP header) to their pages (or servers), just to get standards compliance. I'll code my site to standards compliance. Other sites will sit "broken" and, if the user wants, they can view those sites with or without standards compliance. Why did they not come up with this before?

Post Notes

Of course, the best thing would be to just ship IE8 with full (as full as it will be) standards-compliant mode, leaving behind the bloat introduced by carrying two or three rendering engines. Make it a user option to have either IE7 or IE8 installed or, if the user so chooses, both installed side-by-side.

If we must have a proprietary HTTP header, consider James's idea of an era-based header, though I would argue that the "current era" should be the default. Pick an era that you are (or were) compatible with, and render era-less sites with standards compliance. And, of course, let the user override the era if they so choose.

Finally, I very much like the idea of modular rendering engines. You can have whichever interface you like, further combined with whichever rendering engine you like. Want to use the customizable interface of FireFox with IE8's Acid2-capable engine? No problem. This could even be enhanced with an option to use specific engines on a per-tab basis (for those browsers with tabs); this would inevitably bloat the program (per-instance, not every time), but it would be invaluable for web developers working on Linux or Mac (Testing the same site in IE6, IE7, FF2, and Opera, all from the FireFox interface?? Cool!). I mean, how long have computer users had operating systems with alternate shell capabilities (for example, Windows and LiteStep, or, more obviously, linux and your choice of Gnome/KDE/XFCE/etc)? Why should browser users not have the same capabilities?
(This idea of modular engines was not originally mine, but I cannot for the life of me figure out where I read it originally. If anyone has a link to a place where the idea is more fully fleshed out, please do share :D )

No comments: