Re: why TITLE, not TITLE?

James Aylett (sja20@hermes.cam.ac.uk)
Fri, 9 May 1997 21:11:46 +0100 (BST)


Date: Fri, 9 May 1997 21:11:46 +0100 (BST)
From: James Aylett <sja20@hermes.cam.ac.uk>
To: Paul Prescod <papresco@calum.csclub.uwaterloo.ca>
cc: Chad Owen Yoshikawa <chad@CS.Berkeley.EDU>,
Subject: Re: why TITLE, not TITLE?
In-Reply-To: <33737DE4.2379423B@calum.csclub.uwaterloo.ca>
Message-ID: <Pine.LNX.3.95.970509211000.8021Q-100000@crystal.clare.cam.ac.uk>

On Fri, 9 May 1997, Paul Prescod wrote:

> I would encourage you to modify the DTD rather than the parser. Once
> you've hardcoded that error recovery crap there is no easy way to go
> back. Plus your users might be interested in the ability to test their
> pages out against multiple DTDs: "Does this conform to HTML 2.0? 3.2?
> Extended HTML?"

Having said that, you may need your parser to be somewhat error-allowing.
There are certain cases of broken HTML which simply cannot be represented
in a valid DTD (Stewart Brodie's example of broken comments, for
instance).
This could, however, be comfortably accomplished by having a preparser
which attempts to knock invalid HTML into whicever DTD your parser is
written for (or is using at the moment).

Just a thought,
James

-- 
/--------------------------------------------------------------------------\
   James Aylett -- Crystal Services (crystal.clare.cam.ac.uk) Ftp and Web
            Clare College, Cambridge, CB2 1TL -- sja20@cam.ac.uk