Re: Scripts...

On Sat, 2002-05-11 at 07:45, Bjoern Hoehrmann wrote:

> >Might it be a desirable feature to check that `href' has as its value a
> >valid URI, that `type' has as its value a valid MIME type, or that
> >`lang'/`xml:lang' have valid language codes?  It wouldn't be an error,
> >since the DTDs don't specify (except in comments) anything but CDATA,
> >but a warning might be useful.
> 
> Certainly.

Agreed, but given the limitations of DTDs and the fact that validator
uses (o)nsgmls, it would be currently tricky and hacky to implement that
(unchecked, from memory, kick me if this is BS).  For example, DOM tree
of the to-be-validated document available to validator would help.

Potential candidates for attribute value validation are at least the
language and MIME types mentioned above, plus numbers, pixels, lengths,
fixed-valued attributes and ids, names and idrefs.  I've collected some
of these to [1].

<plug>
gmuck, <URL:http://gmuck.sourceforge.net/>, has some of these
capabilities.
</plug>

Anyway, hopefully at some point of time we'll have an official and
strict enough (with well-defined types) XML schema for XHTML to validate
against.

[1]
<URL:http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/gmuck/gmuck/SPECS?rev=1.3&content-type=text/vnd.viewcvs-markup>

Cheers,
-- 
Ville Skyttä
ville.skytta@iki.fi

Received on Saturday, 11 May 2002 04:41:29 UTC