W3C home > Mailing lists > Public > www-validator@w3.org > August 2003

Re: DOCTYPE options on http://validator.w3.org/file-upload.html

From: Jukka K. Korpela <jkorpela@cs.tut.fi>
Date: Tue, 12 Aug 2003 11:26:17 +0300 (EEST)
To: Frank Ellermann <Frank.Ellermann@t-online.de>
cc: www-validator@w3.org
Message-ID: <Pine.GSO.4.50.0308121105560.23554-100000@korppi.cs.tut.fi>

On Tue, 12 Aug 2003, Frank Ellermann wrote:

> <URL:http://validator.w3.org/check?uri=http%3A%2F%2Ffrank.ellermann.bei.t-online.de%2Fhome%2Ftest%2Fx1.htm&charset=iso-8859-15+%28Latin+9%29&doctype=HTML+3.2&verbose=1>

That validation report shows that the validator _has_ recognized the
choice of an HTML 3.2 doctype, yet complains about lack of doctype.
Using the "Revalidate" button does not help.

So this is not related to <option> values (the source code of the
validation report has <option selected="selected" value="HTML 3.2">HTML
3.2</option>), or to my notes on setting the selected attribute (my
suggestion still stands).

Rather, it's about the validator requiring a DOCTYPE, despite having a
menu for selecting DOCTYPE. The explanation at
says this explicitly: "The Validator is more insistent on this point than
WebTechs was, which would insert a DOCTYPE on the fly for you; The
Validator requires that your DOCTYPE already be in the document."

So why does it mislead people by containing a pulldown menu for selecting

If you ask me, it's that requirement that should be removed, not the menu.
This is especially because we know that most current browsers (ab)use
DOCTYPE declarations. The page mentioned above contains seriously
wrong information when it says: "Most Web browsers don't actually use an
SGML parser (in fact, none that I'm aware of do), and so they don't need a
DOCTYPE declaration, and will ignore it if present." Most browsers do
_not_ ignore DOCTYPE; instead they use it in an absurd guessing game
called "DOCTYPE sniffing". For this reason, an author who wants his
documents to be processed according to W3C specifications as far as
possible should use a certain variant of HTML 4.01 Strict DOCTYPE to avoid
making browser go into an intentionally buggy mode (or "quirks mode").
Validation is a different issue, in reality, and a good validator should
let the user select a DOCTYPE from a menu, overriding any eventual
DOCTYPE in the document itself. Otherwise authors will very often need to
create a separate copy, with the DOCTYPE changed, just for validation.

(Of course, if you can make the browsers behave right now, requiring
DOCTYPEs in documents themselves would be much more reasonable.
But not necessary of course.)

Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/
Received on Tuesday, 12 August 2003 04:26:20 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 November 2015 11:01:19 UTC