[whatwg] Validation

On Tue, Jul 21, 2009 at 11:22 AM, Kristof
Zelechovski<giecrilj at stegny.2a.pl> wrote:
> !DOCTYPE html6 would be an abomination, unless the root element changes to
> html6 also :-)

Also it would trigger quirks mode in many existing browsers, and in
any conforming HTML5 implementation. You'd have to use something like
<!DOCTYPE html SYSTEM "6"> as the shortest string that provides a
version identifier, if you insist on putting it in the doctype.

(The HTML5 doctype reflects that in practice there aren't several
independent carefully-separated languages - there's just a single
vaguely-defined mess called HTML, described in a range of
specifications and sometimes not specified at all, implemented
incrementally with various extensions and bugs and missing features in
various browsers, with people writing pages that mix all the different
features together. The version numbering is an artifact of the W3C's
process of developing a numbered sequence of specifications, and isn't
aligned with how HTML browsers or documents are usually written.

If you want to check that your pages are compatible with certain
browser releases, the language version number is a very bad
approximation - you'd want a tool that understands what features IE10
supports (maybe some (but not all) from HTML4, some (but not all) from
HTML5, some proprietary extensions, etc), and it would be misleading
to think that a pure HTML-version-N validator is going to be good
enough for that. Maybe you want some in-band mechanism for identifying
which pages a spider should check with which rules, but then something
like <meta name="check-ua-compatibility" content="ie=10;fx=5"> seems a
better solution than a language version number in the doctype; if the
problem is real, it should be examined independently of these
particular solutions.)

-- 
Philip Taylor
excors at gmail.com

Received on Tuesday, 21 July 2009 04:02:16 UTC