This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
In order to extract CSS rules and declarations from HTML/XHTML documents, the CSS Validator needs to parse these documents. Therefore, it needs to determine whether a document is HTML or XHTML. The method currently in use is not very sophisticated; the CSS Validator only looks for an XHTML namespace declaration. In particular, it ignores XML declarations and XHTML document type declarations. However, the presence of these declarations is a very reliable indicator for XHTML, so the CSS Validator can safely parse the document as such. <http://jigsaw.w3.org/css-validator/validator?uri=http://schneegans.de/temp/no-xmlns.html> does not use an XML parser. Otherwise, the well-formedness violation would be detected. Furthermore, the CSS Validator fails to detect a namespace declaration when it is preceded by too many characters. Again, <http://jigsaw.w3.org/css-validator/validator?uri=http://schneegans.de/temp/late-xmlns.html> does not use an XML parser. Parsing XHTML documents as HTML may incorrectly throw errors, e.g. <http://schneegans.de/temp/space-preserve-no-namespace.html> is valid XHTML and conforms to Appendix C guidelines, although <http://jigsaw.w3.org/css-validator/validator?uri=http://schneegans.de/temp/space-preserve-no-namespace.html> complains about the "xml:space" attribute.
Thank you for adding the issue to the bug tracking system. For reference, this was also discussed on the mailing-list: http://lists.w3.org/Archives/Public/www-validator-css/2006Aug/thread.html#msg15
I think this bug is moot now that we replaced our dual parser with tagsoup. Need to test and close.