[WEB4LIB] Re:Document declarations

Thomas Dowling tdowling at ohiolink.edu
Fri Nov 3 10:21:30 EST 2000


Ton Barry wrote:
> At 6:24 AM -0700 27/8/2000, Karen G. Schneider wrote:
> >I conducted a massively
> >informal survey (hit ten websites mentioned in postings) and observed
that
> >none of them included HTML declaration statements...
>
> Of the 37 univerity web library web sites in Australia only 13 use
> DOCTYPE statements.
>


The percentage is about the same for academic and public libraries in the
US (I checked about 2500 pages gathered in September).  However...

To be useful, the doctype declaration must be correct.  Fully 40% of the
doctypes referenced in these pages fail to match any DTD in the W3C
validator's catalog and another 18% reference doctypes that are almost
certainly wrong.  The most common reason for the first problem is that the
doctype declaration just fails to match on case sensitivity.  Another
problem is that editor programs lock people into a doctype that doesn't
exist or is patently wrong.

Example of the first problem--30% of all pages with doctypes have:

  -//w3c//dtd html 4.0 transitional//en

Instead of:

  -//W3C//DTD HTML 4.0 Transitional//EN

Since the public identifier for the DTD is case sensitive, none of these
documents will validate.


Example of the second problem--16% of all pages with doctypes have:

  -//IETF//DTD HTML//EN

This is a valid public identifier, but it's for HTML 2.0.  This gets put
into documents by FrontPage, versions 2.0 through 4.0, Publisher 97, Word
97, and some versions of Pagemill and Home Page.  Needless to say, none of
these documents are actually in HTML 2.0.

As has been pointed out, there are very limited needs for a doctype
declaration, so you have to wonder why these programs bother to put one in
at all, if they can't be bothered to pick one that's at least an
approximation of the code they spew out.  IMO, they shouldn't put one in
until and unless they can guarantee valid markup under the DTD chosen
(which should be the default option in all editors, again IMO).


Thomas Dowling
OhioLINK - Ohio Library and Information Network
tdowling at ohiolink.edu



More information about the Web4lib mailing list