what if i define two defferent 'xmlns' for a namespace?
<nsa:aelement xmlns:nsa="a">
<nsa:aelement xmlns:nsa="b">
</nsa:aelement>
</nsa:aelement>
Namespace prefix bindings are scoped. The descendants of the outer
element which reference the nsa: prefix understand it to mean the
namespace "a", EXCEPT where that's overridden by another definition as
you've done here. In this example the inner element and all its
descendants understand nsa: to mean the namespace "b".
Remember, the prefix is just a syntactic shorthand. What really carries
meaning is the combination of the URI the prefix is bound to plus the
localname following the prefix.
WARNING: These are NOT good namespace names. Namespace names should be
absolute URI references, according to the W3C. If you're going to use
something short and sloppy, in an example, you should at least use
"
http://a" or something of that sort. (There was a major debate about
this in the W3C, due to a combination of sloppy wording in the first
draft of the namespace spec and some fuzzy thinking about whether there
was any useful way to interpret relative namespaces. The decision was
made to deprecate relative namespace URIs until and unless someone
convinces the W3C that they are both necessary and practical.)