Next in thread → Next in month →

Re: [xml-dev] Default namespace for attributes?

From
David Carlisle <>
To
Date
2006-07-17T08:58:27Z
ID
<>
Thread
Re: [xml-dev] Default namespace for attributes?
The main advantage of the rule for unprefixed attributes is that you
don't have  to prefix all the attributes when prefixing elements.

If you have an xhtml <a href="foo">bar</a> and need to put that in a
context where the defualt namespace is something else 9eg docbook 5),
then you bind h to the xhtml namespace and go
<h:a  href="foo">bar</a>
but if unprefixed attributes were affected by the default namespace
binding then this would be wrong ad href would be an attribute from 
the docbook namespace. You'd have to go
<h:a  h:href="foo">bar</a>
and the xhtml spec would have to be changed so that it defined
attributes in the xhtml namespace.


So the current rule is the rule you want if you think that the majority
of attributes, even in namespaced vocabulary, should be unprefixed.


David
Next in thread → Next in month →