Re: Suggestion for Change in HTML Validatior

On Mon, 8 Jan 2001, David M Abrahamson wrote:

> I have recently come across a commercial web site that uses HREFs of the
> form <A HREF="url:">.

That's very strange usage, but it's not a validation issue.

> Since the URI bracketing in an HREF attribute value is done using "..." or
> '...', not "URL:..." or 'url:...', I cannot see any requirement on an HTML
> browser to find and strip out the "url:".

You are quite correct. The use of url: there must be based on some
odd misunderstanding. But...
> Perhaps you might like to modify the validator to spot this form of error?

It is none of a validator's business to check what's inside an HREF
attribute, since such an attribute is declared as being CDATA, which
means roughly speaking "anything goes". So
HREF="foo:bar:zap hello world"
must pass validation, though it of course does not comply with the
specification. The HTML 4.01 specification tries to explain the meaning of
CDATA at and although it is
neither very illustrative nor very exact in its content, it nevertheless
gives the message that in the formal syntax (which is all that a validator
deals with) a CDATA value is just a string of characters.

Well, literally it's

href        %URI;          #IMPLIED  -- URI for linked resource --

but %URI; is just a synonym for CDATA:

    -- a Uniform Resource Identifier,
       see [URI]

(note that the text between --'s is a comment only and has no
significance in validation).


Received on Monday, 8 January 2001 04:12:34 UTC