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

Re: Error Message Feedback [] No error messages yet Not valid

From: Terje Bless <link@pobox.com>
Date: Tue, 30 Aug 2005 05:50:55 +0200
To: www-validator@w3.org
cc: "Dr. Clue (A.K.A Ian Storms)" <drclue@drclue.net>
Message-ID: <D0202000e-1042-4785BBE576924FC69A370707390CE5A3@pounder.tj.unn.no>

Dr. Clue (A.K.A Ian Storms) <drclue@drclue.net> wrote:

>No error messages , but not valid either?
>
>Is it against the rules to have a custom DTD shared across domains? I use
>this custom DTD with my main site and it validates.
>
>Heres the link to the validator dislaying the weirdness I observed.
>http://validator.w3.org/check?uri=http%3A%2F%2Fresume.drclue.net%2Findex.
>html&charset=%28detect+ automatically%29&doctype=Inline&ss=1&verbose=1
>Heres the link to the page being validated.

The Validator is actually telling you what's wrong, if in a slightly obtuse way.

The validator receives something with a MIME Media Type of “text/html”, which is
used to serve both traditional SGML content — i.e. things with the same SGML
Declaration as HTML 4 and its predecessors — and XML derived document types.

Since there is no way to disambiguate in the absence of a known FPI it has to
guess and guesses (defaults to, actually) SGML mode.

Since your DTD is derived from the XML-based XHTML DTD, the validator finds
several errors in the DTD — not the document itself — and thus fails the
validation.

The errors found in the DTD are not reported — good or bad, this is as designed
— but the “not valid” status is still reported.


If you try serving the document with an application/xhtml+xml media type the
validator should pass it (or report any errors if the document isn't valid)
since it will then default to XML mode.

If you want to continue serving the document as “text/html” I'd suggest deriving
your custom DTD from the HTML 4.01 DTD instead of the XHTML DTD.


A future version the validator /may/ implement an explicit user switch to force
either XML or SGML mode, but I'd consider this somewhat of a hack in any case
and it's likely to not get implemented until we have pluggable backend parsers —
with a a new parser for XML — in place (which may be a while).

-- 
> …publicity rights, moral rights, and rights against unfair competition…
Well, you've got me there.   I have no idea what any of those have to do with
SGML. Next you'll be claiming that running NSGMLS constitutes an unauthorized
public performance of SGML.                                  -- Richard Tobin
Received on Tuesday, 30 August 2005 03:51:10 GMT

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