HTML5
Used to be, I would only use a strict XHTML doctype on any webpage I authored. I looked down on people using html4 or transitional even, thinking it was pretty worthless (which it is ;).
Why is XHTML better?
- XML can be validated, extended, and written by machines easier since it's parsing rules are standardized.
- XSLT
- Strictness (if it isn't valid xml, it doesn't work)
Any cons?
- Strictness. The idea of a comment from someone on my blog being able to derail the entire page because of invalid xml is pretty stupid.
- application/xml support sucks. Violating the spec just to please IE seems ok at first, but it really is just another thing to worry about. What if the mechanism that does this switch freaks out or doesn't work with IE9 or something?
But I don't care now, because HTML5 is the future
HTML 5 actually provides all the positives of XHTML without any of the cons. It's parsing rules are declared fully, anyone can make a parser and validation will be much more useful. HTML 5 will also define XHTML 5, which will be essentially the same but with XML compatibility, so XSLT is still an option. And strictness is still possible, but doesn't derail the entire thing.
You also get new form inputs, section, nav, header, footer, and other cool tags. You get data- attributes on elements, you get DOM parity with the parsing model, you get SQL storage in the browser, the ability to run apps offline, etc. You really get all the ideas we all already agree on.
Any really, why should HTML have it's own spec and be it's own language? Why do we have to use XML for everything? I already use JSON for almost all of my inter-application communication when I write webapps. Not because it works natively in javascript (I'm not even using it there much), because it works everywhere. There are not attributes or namespaces or anything, just data. It beats the pants off XML for most everything I do. And parsing JSON is dead simple, anyone can write a parser (sound familiar).
And really, the main reason HTML5 is the best to me is because the author of and contributors to the spec care about what works now. They are not hesitating to push things forward, but they are not blindly blazing a trail that no one is going to follow.
Is there anything that is in XHTML 2 that (X)HTML 5 will not have that matters? Contact me and I will amend any comments if valuable.
Also, here is a google search in case you care.
Update: Probly the best overview at immike.net. A quote:
Both working groups have embraced the coming Semantic Web by allowing developers to embed richer metadata in their documents. As with forms, the XHTML2 working group has embraced a more sophisticated technology, while the HTML working group has kept things simple.
The complex looks nice sometimes, but usually the simple wins in the end.
Update 2: An article disagreeing with me.
Update 3: Some more links:
