The Great XHTML DOA WTF Debate
As the dust begins to settle on the debate sparked off by the W3C’s recent announcement that work on XHTML 2 is expected to stop at the end of 2009 to focus resources on the development of HTML 5, it’s worth pausing to reflect upon what this means to web designers and developers moving forward.
Judging by the often heated comments made over the last fortnight, this is clearly a topic that many feel passionate about and weren’t afraid to express an opinion on. Indeed, at times it appeared as if this were the only thing on many notable standardistas’ minds.
The original announcement quickly drew comment from Jeffrey Zeldman, sparking a protracted, and at times less than productive, discussion in the comments of his post XHTML DOA WTF. It even gave rise to a short poem - This Is the House, courtesy of Mark Pilgrim - again, unsurprisingly, sparking a heated discussion.
Watching from the sidelines it’s debatable what many of the the cheap shots being traded left, right and centre achieved. Surely what most web designers and developers want, is to do the best that they can with the tools they have at their disposal? A point Eric Meyer summed up neatly.
First things first - and worth noting, given the often repeated, post-announcement mantra that, “XHTML is dead” - XHTML is not dead, it still exists as XHTML 5. If you don’t believe us, ask the doctor, he couldn’t be any clearer:
HTML 5 + XML = XHTML 5
So, XHTML 5 is alive and well, but XHTML 2 is dead? Admittedly this might appear confusing, perhaps it’s best to give this some context.
A Little History
To understand the current situation it’s best to get a little background, specifically to ask, what was XHTML 2 all about and how did it differ from HTML 5?
One of the main differences between the development of the XHTML 2 and HTML 5 standards lay in the XHTML 2 Working Group’s controversial decision to discard backward compatibility and create a language - based solely on XML - that was unconstrained by current browser implementations, limitations and history.
This decision to break with the past in an attempt to create a theoretically ‘pure’ vocabulary arguably resulted in XHTML 2 becoming an increasingly theoretical proposition, lacking pragmatism, and is perhaps one reason the W3C reached its recent conclusion.
HTML 5, on the other hand, has been developed with current and future browser development in mind and, as a consequence, has recently been gaining significant momentum. Driven by pragmatism, it has recently emerged as a the W3C’s choice for “accelerated developement”. John Allsop summarises it best:
One of the lessons the web continues to teach us is that it values pragmatic development over theoretical perfection.
The pragmatic approach taken when developing HTML 5 perhaps helps to explain why it has emerged as the frontrunner in the web’s evolution, with the W3C stating that, through its recent decision, “it hopes to accelerate the progress of HTML 5 and clarify [the] W3C’s position regarding the future of HTML.”
So, XHTML? Was it all just a waste of time?
Is XHTML DOA (WTF)?
Herein lies the confusion.
The W3C might have chosen to focus its future efforts on supporting the development of HTML 5, however, this does not mean that the benefits of learning (and using) XHTML are suddenly redundant.
For one thing XHTML’s strict rules - lowercase markup, quoted attributes, correctly nesting elements, closing all opened tags… - are a lot easier to follow and remember than the rather more lenient rules of HTML 4.01.
Not only does XHTML’s stricter syntax leave some feeling nice and comfy, it’s also easier to learn, one reason many are still embracing it. Drew McLellan states, “In my experience simple, strict rules are much easier to learn … rules that require no thought, and result in uniform, predictable markup.” Ian Lloyd agrees, “I still believe that it’s better to teach XHTML syntax rather than HTML, so that beginners learn rules rather than (arguably lazy) shortcuts.”
This emphasis on the creation of well-formed markup might be argued as the catalyst that, “taught a generation of developers what good code should or could look like,” as Jonathan Snook (an HTML 4.01 aficionado) puts it. It also offered the “opportunity to rethink markup,” as Jeffrey Zeldman summarised in his follow up post In Defense of Web Developers:
XHTML’s introduction in 2000, and its emphasis on rules of construction, gave web standards evangelists like me a platform on which to hook a program of semantic markup replacing the bloated and unsustainable tag soup of the day. The web is better for this and always will be, and there is much still to do, as many people who create websites still have not heard the call.
At the end of the day it boils down to choice, as Jeremy Keith points out in his excellent article Misunderstanding Markup:
The death of XHTML 2 does not mean the death of XHTML syntax. If you want to continue to close all tags and quote all attributes, you can do so. You can either use the existing XHTML 1 spec or you can use HTML 5.
The bottom line? What you’ve learned to date will form a solid foundation on which to build moving forward.
We operate in an industry that changes rapidly. Keeping abreast of developments as they emerge is essential to maintain an understanding of contemporary practice moving forward.
The following links are worth setting aside a few hours for and reading, if only to enable yourself to fully appreciate the complexities of the current debate from the different participants’ perspectives.
It’s perhaps best to start with the two posts by Mr Zeldman that started the ball rolling: XHTML DOA WTF and In Defense of Web Developers, both are well worth reading, particularly their extensive comments.
Lachlan Hunt’s A Preview of HTML 5 at A List Apart is still well worth reading, despite being published in 2007; John Allsop’s more recent Semantics in HTML 5, also at A List Apart, is an excellent and insightful exploration of semantics in HTML 5. Lastly, as HTML 5 takes hold, it’s worth checking in periodically with the HTML 5 Doctor.