W3C home > Mailing lists > Public > www-validator-css@w3.org > May 2001

Re: CSS validator stricter than XML validator

From: Philippe Le Hegaret <plh@w3.org>
Date: Thu, 10 May 2001 16:42:19 -0400
Message-ID: <3AFAFD2B.79F9B212@w3.org>
To: Bjoern Hoehrmann <derhoermi@gmx.net>
Cc: Claudio Nieder <private@claudio.ch>, www-validator@w3.org, www-validator-css@w3.org
Bjoern Hoehrmann wrote:
> The HTML Validator treats the document as compatible HTML document, the
> CSS Validator as XML document. You define
> 
>   <meta http-equiv="Content-Type" content="text/html;
>                                             charset=iso-8859-1" />
> 
> in the document, the literal [ιδ...] are recognized as ISO-8859-1
> characters.

> In XML document, the encoding must be declared in the XML
> declaration, your document doesn't have an (or 'a'?) XML declaration, so
> the document is treated as UTF-8-encoded and the octets for the
> mentioned 8-Bit-characters in ISO-8859-1 aren't valid UTF-8 sequences.

Not only in the XML declaration but also in the protocol. See
ftp://ftp.isi.edu/in-notes/rfc3023.txt.

> I'd say it's a bug in the CSS Validator anyway, if it's text/html, treat
> it as text/html.

I disagree on this point:
[[[
XHTML Documents which follow the guidelines set forth in Appendix C,
"HTML Compatibility Guidelines" may be labeled with the Internet Media Type
"text/html"
]]]

-- XHTML 1.0: The Extensible HyperText Markup Language
http://www.w3.org/TR/2000/REC-xhtml1-20000126/#media
Wed, 26 Jan 2000 08:25:30 GMT

and XHTML documents are following the rules of XML:
[[[
In order to be consistent with the XML 1.0 Recommendation [XML], the user
agent must parse and evaluate an XHTML document for well-formedness.
]]]

-- XHTML 1.0: The Extensible HyperText Markup Language
http://www.w3.org/TR/2000/REC-xhtml1-20000126/#uaconf
Wed, 26 Jan 2000 08:25:30 GMT

per the XML 1.0 specification:
[[[
It is a fatal error if an XML entity is determined (via default, encoding
declaration, or higher-level protocol) to be in a certain encoding but
contains octet sequences that are not legal in that encoding.
]]]

-- Extensible Markup Language (XML) 1.0 (Second Edition)
http://www.w3.org/TR/2000/REC-xml-20001006#charencoding
Thu, 05 Oct 2000 12:19:51 GMT

Philippe
Received on Thursday, 10 May 2001 16:42:32 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 27 June 2012 00:13:58 GMT