[Bug 1762] UTF-8 BOM in XHTML breaks CSS validator

http://www.w3.org/Bugs/Public/show_bug.cgi?id=1762





------- Additional Comments From ylafon@w3.org  2005-07-22 10:13 -------
(In reply to comment #3)
> Okay, it seems this happens if Content-Type:text/html with no charset parameter 
> and a BOM. So this is probably the result of how the HTML parser with its XHTML 
> sniffing interact with xerces. The Validator might be transcoding to UTF-8 
> before it passes the document to Xerces and in a character stream a bom may 
> indeed not appear. It seems to work for application/xhtml+xml and text/html 
> with a charset parameter in the HTTP header.

The current code does this
if the mime type has a charset parameter use it,
if not, then if the mime type is text/html -> use iso-8859-1

Received on Friday, 22 July 2005 10:13:12 UTC