[jdom-interest] Namespace issues, et al.

Elliotte Rusty Harold elharo at metalab.unc.edu
Tue Feb 25 08:29:46 PST 2003


At 9:09 AM -0700 2/25/03, Alex Rosen wrote:


>(2) As someone mentioned, it's often up to the parent element to decide
>how to interpret its attributes. The XHTML <a> element could either
>specify that it has a child "href" in the null namespace or in the XHTML
>namespace.

No, XHTML can't do that. Please let's not confuse the issue further. 
The href attribute of the XHTML a element has no namespace name. 
There is no wiggle room on this. The XHTML spec cannot decide to do 
this one way or the other. The namespaces spec is authoritative on 
this point.

The XHTML spec can say what browsers should do with href attributes 
of a elements, but if it wants the href attribute to be in the XHTML 
namespace, then it must assign a prefix to that attribute which is 
mapped to the XHTML namespace. It can't do this by fiat in the spec.
-- 

+-----------------------+------------------------+-------------------+
| Elliotte Rusty Harold | elharo at metalab.unc.edu | Writer/Programmer |
+-----------------------+------------------------+-------------------+
|           Processing XML with Java (Addison-Wesley, 2002)          |
|              http://www.cafeconleche.org/books/xmljava             |
| http://www.amazon.com/exec/obidos/ISBN%3D0201771861/cafeaulaitA  |
+----------------------------------+---------------------------------+
|  Read Cafe au Lait for Java News:  http://www.cafeaulait.org/      |
|  Read Cafe con Leche for XML News: http://www.cafeconleche.org/    |
+----------------------------------+---------------------------------+



More information about the jdom-interest mailing list