I'm wondering if I should bother at all about the markup language, as long as i produce valid markup.
I've read articles that point out HTML is the best choice and they come directly from the horse's mouth (the browsers implementors!):
- http://webkit.org/blog/68/understanding-html-xml-and-xhtml/
- https://developer.mozilla.org/en/Mozilla_Web_Developer_FAQ
Other articles, by James Bennet, make another point that if you're not serving XHTML as XML then you don't want XHTML but HTML.
So i thought that if i wanted to trigger Standard Compliant Mode i should just use HTML strict validation. But that's not the case anymore with at least the most modern browsers (aka everything but IE6): if you have valid XHTML Strict you still trigger Standard Compliant Mode, hence, as long as i produce valid markup, why bother?
In most case, it does not matter. In fact, using XHTML cause more headache. However, there is a few situation that XHTML is needed. I can think of two.
First, if you want to use embeded SVG, you need XHTML.
Second, if you want to use HTML mark up as XML. Sometime (for unknown reason), I found that my AJAX request verify the code even when I mark it to be html or text. And to quickly avoid that, I change it to XHTML.
That is all.