W3C home > Mailing lists > Public > www-validator@w3.org > October 2004

Re: xhtml Validator bug?

From: Jukka K. Korpela <jkorpela@cs.tut.fi>
Date: Thu, 21 Oct 2004 06:24:27 +0300 (EEST)
To: www-validator@w3.org
Cc: GVE <gve@altervista.org>
Message-ID: <Pine.GSO.4.58.0410210615050.21767@korppi.cs.tut.fi>

On Thu, 21 Oct 2004, Bjoern Hoehrmann wrote:

> ><script type="text/javascript" src="script.js" />
> >
> >It should be:
> >
> ><script type="text/javascript" src="script.js"></script>
>
> There is no specification that says so,

There is. The XML specification (which applies to all XML based languages
including XHTML) says:

"Empty-element tags MAY be used for any element which has no content,
whether or not it is declared using the keyword EMPTY. For
interoperability, the empty-element tag SHOULD be used, and SHOULD only be
used, for elements which are declared EMPTY."
   http://www.w3.org/TR/REC-xml/#sec-starttags

So it simultaneously says that the construct is allowed and should not be
used. And naturally this implies the statement "It should be: - -".
Well, for some values of "should". The XML specification's wordings are
somewhat strange, and "for compatibility" is defined as "describing a
non-binding recommendation"; but "should" itself means less than "shall".

> the HTML Working Group only
> shared their observation that using the latter works better in HTML user
> agents for which it follows that if that is a concern, you are better
> off using the latter.

And the XML specification says basically the same in a more general
framework.

> While such observations are indeed of some use,
> there is nothing wrong with not reporting such observations, so this is
> not a bug.

Indeed. And reporting an error when there is no markup error, as defined
by the formal rules of SGML or XML and by the DTD used, would be a bug.

-- 
Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/
Received on Thursday, 21 October 2004 03:28:36 GMT

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