Given a document:

        <one xmlns='asdf'><two three='four'></two></one>

Using the XPath:

        //*[name()='one']/two/@three

I get different results with Xalan (works) and dom4j (fails).

The XPath spec just confuses me, but it says:

A QName in the node test is expanded into an expanded-name using the namespace 
declarations from
the expression context. This is the same way expansion is done for element type names 
in start and
end-tags except that the default namespace declared with xmlns is not used: if the 
QName does not
have a prefix, then the namespace URI is null (this is the same way attribute names 
are expanded).

Which seems to mean to mean either that it should work or that it should fail 
depending on which
day I am reading the spec....  Is Xalan right, or is dom4j right?

-Tom


_______________________________________________
dom4j-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dom4j-user

Reply via email to