Re: flakey charset detection

Nick Kew wrote:

>>>p.s. Given that it's XHTML, I find the fact that it even _tried_
>>>     using the META element to be worrisome ... that means that
>>>     parsing this document as XML could give different results,
>>>     which breaks all XHTML goals I ever heard.  Not that I've
>>>     tracked XHTML recently, but this seems like trouble.
>>
> 
> Was that XHTML served as HTML or XML?

HTML.  So it'd be legal to check META ... but as I noted it would be
incompatible with any XML toolset, so this is a "should not do" thing.
Section C.9 of the XHTML 1.0 spec says the xml declaration takes
precedence over META ... I think META charset info in XHTML could
rarely be anything except trouble.


> By serving it as text/html, you're telling us HTML rules apply, including
> the charset you sent with it.  More specifically, Appendix-wossname rules
> for XHTML, which (as Hixie has demonstrated) leads to unavoidable
> contradictions.

I googled to http://www.hixie.ch/advocacy/xhtml ... is that what you mean?

It's undated... he's taken an extreme position that assumes the document
publishers are doing stupid things (stupidity is optional, "should not"),
and I noticed errors in his text.  I think he's biased, as shown by some of
the internal inconsistencies in his argument.  Many people have found that
if there are problems, they're often easy to resolve.  More have found
that using anything _except_ text/html is completely unworkable.

- Dave

Received on Wednesday, 4 December 2002 15:49:00 UTC