xsl-list
[Top] [All Lists]

Re: [xsl] XPath and noname namespace

2008-07-14 08:10:39
I have simple document:<svg xmlns="http://www.w3.org/2000/svg";>
<a>aadsf</a> </svg>

so the element there has name local name a in the namespace
http://www.w3.org/2000/svg

And now "//a" doesn't find a node

That selects elements with local name a in no namespace.
 

I must use //*[local-name() ='a'],

That is possibly inefficient and selects any element with that local
name, a more usual approach is to say

 I must use //svg:a where your stylesheet has
 xmlns:svg="http://www.w3.org/2000/svg";

David

________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs. 
________________________________________________________________________

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>