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

Re: Validator and XML namespaces

From: Tim Bagot <tsb-w3-validator-0006@earth.li>
Date: Sat, 5 Oct 2002 09:39:48 +0000 (UTC)
To: <www-validator@w3.org>
Cc: Miles Elam <miles@geekspeak.org>
Message-ID: <Pine.LNX.4.33.0210050918230.965-100000@213-152-52-166.dsl.eclipse.net.uk>

At 2002-10-04T21:04-0400, Miles Elam wrote:-

> Reference URL: http://geekspeak.corkdog.com/shouldvalidate.html
> Shows erroneous errors about namespace declaration -- "xmlns is not a
> valid attribute".

There are two problems here.

The first is that namespaces are in no way special for validation. The
xmlns:* attributes (and the elements and attributes in those namespaces)
are not in the XHTML 1.0 DTDs, so you can't use them in a valid XHTML 1.0
document. If you want to use other namespaces you will need a DTD that
includes the required elements and attributes. (This is slightly more
practical with XHTML 1.1 and up, using modularisation. DTDs have been
created for using XHTML with MathML and SVG.)

The second is that the validator is not really complaining about the xmlns
attribute (which does exist in XHTML 1.0), but about the xmlns:*
attributes. It is having trouble parsing the output of the SGML parser it
uses, which so helpfully delimits fields using ':'...

Tim Bagot
Received on Saturday, 5 October 2002 05:39:50 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 14:17:34 UTC