aspose file tools*
The moose likes Web Services and the fly likes Resolving namespace using xpath Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Resolving namespace using xpath" Watch "Resolving namespace using xpath" New topic
Author

Resolving namespace using xpath

Shilpa Anju
Greenhorn

Joined: Aug 19, 2005
Posts: 2
Hello,
I have a XML document, that has namespaces in it. I want to use the xpath to search for a specific value of the node. However I am unable to find out how to resolve the namespace.

Can anyone help me with this ?
Nathaniel Stoddard
Ranch Hand

Joined: May 29, 2003
Posts: 1258
XPath has some functions that you can use to "ignore" the namspace if you're certain they're correct. Other than that you could start ripping apart the XML and resolve the namespace prefixes yourself. By the way, what do you mean by "resolve the namespace"?


Nathaniel Stodard<br />SCJP, SCJD, SCWCD, SCBCD, SCDJWS, ICAD, ICSD, ICED
 
Don't get me started about those stupid light bulbs.
 
subject: Resolving namespace using xpath