W3C home > Mailing lists > Public > www-validator@w3.org > February 2006

Re: Direct input doesn't take XML declaration into account for parsing mode selection

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Wed, 08 Feb 2006 08:58:13 +0100
To: Dominique Hazael-Massieux <dom@w3.org>
Cc: www-validator@w3.org
Message-ID: <fj8ju1t4gtv9evd0jm44gu3tbto5bit9o9@hive.bjoern.hoehrmann.de>

* Dominique Hazael-Massieux wrote:
>When using the direct input form for validation with a FPI that the
>system doesn't recognize, the validator defaults to an SGML-parsing,
>even when there is an XML declaration at the top of the input. I think
>the XML declaration should be a good enough hint to switch the
>XML-parsing.

  <?xml version='1.0'?>
  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
  <HTML LANG=de>
  <HEAD>
  ...

That's perfectly legal HTML content. The textarea validation essentially
assumes text/html input and since W3C refuses to define how to tell HTML
and non-HTML text/html content apart, I'm not sure there is much we can
do to resolve this, other than not assuming text/html. The question
would then be what to assume, if anything.
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Wednesday, 8 February 2006 08:04:06 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 25 April 2012 12:14:20 GMT