![]() |
![]() | ![]() | ![]() | Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries [Thread Prev] >Thread Next - Re: XPath and namespaces... XPath and namespaces...To: NULL Date: 1/2/2005 4:07:00 PM Hi, I've got a little bit of a problem when dealing with namespaces and XPath. I'm trying very basic things, like showing all the nodes of one particular namespace. Here is my XPath statement: //*[local-name() = 'buch' and namespace-uri() = 'http://www.example.com/buecher'] Unfortunately this doesn't work. I have found several ways to solve this with XSLT, but I need the pure XPath statement. My XML file looks like this: <?xml version="1.0"?> <!-- Dateiname: Sammlung.xml --> <SAMMLUNG xmlns:buch="http://www.example.com/buecher" xmlns:cd="http://www.example.com/cds"> <buch:ARTIKEL Status="vorhanden"> <buch:TITEL>The Adventures of Huckleberry Finn</buch:TITEL> <buch:AUTOR>Mark Twain</buch:AUTOR> <buch:PREIS>12.75</buch:PREIS> </buch:ARTIKEL> <cd:ARTIKEL> <cd:TITEL>Violinkonzert D-Dur</cd:TITEL> <cd:KOMPONIST>Beethoven</cd:KOMPONIST> <cd:PREIS>14.95</cd:PREIS> </cd:ARTIKEL> </SAMMLUNG> Could anyone please give me a hint how to solve this problem? Thanks, Stefan | ![]() | ![]() | ![]() |
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | |||||
|
