Re: validating wth missing DOCTYPE

On Tue, 30 Dec 2003, Torinthiel wrote:

> Why is it impossible to validate a document without a DOCTYPE.

It isn't. You can use the http://validator.w3.org/detailed.html
interface, which even lets you override a DOCTYPE in the document itself.

Technically, this means a deviation from SGML principles. It is logically
impossible to validate without a DTD, since validation means, by
definition, checking a document against a DTD. And a DOCTYPE declaration
is the way to specify a DTD. But being liberal we might regard the doctype
selection menu as a tool for implicitly creating documents that have the
DOCTYPE specified.

> Ok, I
> know this documents does not validate, and there should be some warning
> about it,

If a document does not validate, a validator must, by definition,
issue an error message.

> but for what are then tne fields for selecting charset and
> doctype?

It seems that you _have_ used the extended interface. Then I cannot see
what you are referring to.

> I mean I have a page. This page doesn't have a DOCTYPE. Ok, I know it's
> not valid. But I want to force validating with one specific DOCTYPE to
> sre how many other errors it contains. And I cannot.

You can, by adding a DOCTYPE declaration or by using the extended
interface.

> And as this is not
> my page, I just want to come out with several improvement ideas, I
> cannot just add the doctype and revalidate.

You can, since you can create a copy of the document and edit it for
validation - though in rare cases, this might be regarded as copyright
infringement.

-- 
Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/

Received on Tuesday, 30 December 2003 06:35:00 UTC