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

Re: DTD problem, or validator problem?

From: Matthew Wickline <wickline_m@pcfnotes1.wustl.edu>
Date: Thu, 16 Aug 2001 07:51:10 -0500
Message-ID: <3B7BC1BD.740F0A46@kids.wustl.edu>
To: www-validator@w3.org
CC: Tim Bagot <tsb-w3-validator-0005@earth.li>


Tim Bagot wrote:
> <empty/> is terminated in XML by the '>', but in SGML by the '/',
> so that the '>' is interpreted as character data,


ahh.... I see.

So, in an HTML 4.01 document,

    <hr />

*should* be interpreted as a horizontal rule element followed by an
(improperly) unescaped greater than sign?

In that case, shouldn't the validator be giving an error that I've got
unescaped greater than signs in the body of the HTML?

I had originally thought that the bug was in how the validator (or DTD)
dealt with empty containers in the HEAD. Based on your explanation of
that behvavior, it would seem that if it's doing the right thing in the
HEAD, then it isn't doing the right thing in the BODY. If I'm following
you, it sounds like *neither* of my two examples should validate.

...or am I still missing something here? Is the escaping of [<>"&] not a
part of the DTD, but one of those things which is specified in non-DTD
fashion in accompanying text or something, and therefor not something
the validator can conveniently address?

-matt



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html><head><title>This is OK by the Validator</title>
    <meta http-equiv="Keywords" name="Keywords" content="no slash">
</head><body><br /><hr /></body></html>




<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html><head><title>This is *NOT* OK by the Validator</title>
    <meta http-equiv="Keywords" name="Keywords" content="slash" />
</head><body><br /><hr /></body></html>
Received on Thursday, 16 August 2001 08:51:11 GMT

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