Anyone else confused?
I read through the WSG thread that came from and followed up a lot of the links and if like me you're making the transition to stronger use of CSS based development the xhtml v's html issue seems to be summarised like this:
The issue seems to be whether you are using this...
meta http-equiv="Content-Type" content="text/html
...as opposed to this...
meta http-equiv="Content-Type" content="application/xhtml+xml (or text/xml)
...in an xhtml document.
The latter is telling the end user agent it's an xml document and therefore apply xml procedures while the former tells it to apply html procedures. therefore an xhtml document with content="text/html will be treated like an html document which negates some of the benefits of using xml in the first place. Please correct or further detail where necessary.
The above discussion while relevant and interesting does seem a little academic. It seems to me that xhtml is actually easier to follow than HTML simply because has more consistent markup rules. e.g. Considering explaining to colleagues...
Lower case for ALL HTML element and attribute names
ALL elements other than those declared in the DTD as EMPTY must have an end tag
Empty elements must either have an end tag or the start tag must end with />
ALL attribute values must be quoted
etc...
In contrast consider explaining HTML that looks like...
<TABLE WIDTH=100 BORDER=1>
<tr>
<td><p><IMG SRC="image.jpg" alt="Image"><br></P></TD>
</TR>
</table>...and yet is valid html 4.01.
It seems to me that aside from the technical discussions, from the perspective of churning out web pages the consistency of markup is a large part of what the standards are all about. It's a lot like an application development team deciding their standard will be tabs instead of spaces or...
function whatever()
{
...
}rather than...
function whatever() {
...
}Anyway, just thought I'd throw that in as a thought for anyone else getting the feeling they're walking the wrong way on an escalator!
Nick
On Sunday, Jan 4, 2004, at 19:21 Australia/Sydney, Peter Firminger wrote:
It may be a good time to repost this from Russ on 5th July 2003:
<repost>
Peter and I have been (endlessly) discussing the pro's and cons of XHTML
over HTML4.01. We made the move from HTML4.01 transitional to XHTML 1.0
transitional mid last year, and while the transition was quick, we have been
aware of two major issues with XHTML that make it not-so-good choice.
WORRIES ABOUT XHTML 1. Some people say that if you are using XHTML you should be serving "application/xml" as a mime type rather than "text/html". Here are some articles on the subject: http://www.hixie.ch/advocacy/xhtml http://www.goer.org/Journal/2003/Apr/index.html#20 http://www.goer.org/Journal/2003/Apr/index.html#29 http://golem.ph.utexas.edu/~distler/blog/archives/000150.html
2. The verity search engine (shipped with ColdFusion and used extensively by
us) seems to have trouble correctly indexing XHTML documents, and requires
filters to be applied to the results to remove ">" characters that have been
escaped by the preceding "/"> (this is likely to be a mime type issue).
ON THE OTHER HAND
There have been many people putting forward reasons for making the switch to
XHTML such as Zeldman and Tantek:
http://tantek.com/log/2003/01.html#L20030114t1345
QUESTION
So, the question is, (keeping in mind the mime type issue especially) can
anyone provide me with a good solid reason (no warm and fuzzy ones) why
XHTML 1.0 is better than HTML 4.01?
Thanks Russ
</repost>
Peter
I don't believe you have to do anything in ColdFusion for XHTML. You just put the appropriate Doctype at the top of the page, just as you would with a static page. CF will output XHTML out of the box with no modifications or special handling at all. You just tell it what you want, as you do with html.
***************************************************** The discussion list for http://webstandardsgroup.org/ *****************************************************
*****************************************************
The discussion list for http://webstandardsgroup.org/
*****************************************************
