• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to use XPath in a XML with namespaces ?

 
author
Posts: 194
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
I need to reference a certain Node in a Document using XPath notation.
The problem is the the XML Document contains Namespaces inside it
f.e.



Using DOMXPath (from weblogic.xml.xpath)


When I Iterate through the Set I can see it's empty.
(On the other hand without namespaces everything is fine.)

So how can I reference a Node that contains a namespace in it ?
Thanks a lot
Francesco
 
Ranch Hand
Posts: 5040
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Do you have a link for some documentation on that weblogic thingy?
They should have some message to 'enable' namespaces.


- m
 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This may help you get a handle on namespaces:

http://www.xml.com/pub/a/2001/05/02/trxml.html
 
reply
    Bookmark Topic Watch Topic
  • New Topic