Forum Moderators: open
I think I need to reverse this decision to go with XHTML and I'm not sure the best way to approach this. Would it be as simple as changing the declaration to XHTML 1.0 and safely serving text/html forever? If so, would it be OK to continue with the .xhtml extensions?
Rewriting the whole site into html would be a total nightmare. I need some suggestions as to the best course of action... thanks.
[edited by: Asia_Expat at 2:01 pm (utc) on Mar. 9, 2008]
For a lot of reasons (stated on this site, actually, but I'm too ADD to go looking for them), it was explained that it's not actually that useful. As you pointed out, it needs to be served correctly. I haven't had much problem with it, and actually like the fact that bad code served as application/xhtml+xml would result in a browser barf. Forces me to write good code.
What I do these days is use XHTML 1.0 Strict served as text/html. It is every bit as anal as XHTML 1.1, but no browser I've ever tested against has had a problem with it being served as text/html. I know, I know, the theory says don't do that, but the facts on the ground knock the theory into a cocked hat.
I use XHTML, because I like being able to validate at 30,000 feet with <oXygen/>, and I like writing code that is cleaner than it needs to be.
Some people go all nuts about the evils of XHTML, just as some people go nuts over the evils of <table> elements and AJAX. It's absolutely amazing how many words they'll dump into a diatribe against it.
I've found that there is never a "One, True Way." We use whatever tools we need to accomplish a given task, and getting hung up at the Kool-Aid barrel has its drawbacks.
In any case, HTML 5 will have two variants: XML and Non-XML. There's nothing wrong at all with non-XML (HTML 4.01 Strict and HTML 5); just as there is nothing wrong with using XHTML 1.0 Strict. It's really a matter of personal style. I've yet to encounter a browser that has a problem with it; and I test the living daylights out of my sites.
Just my $0.02.