I have a simple xml node, and an equally simple xpath query expression, but it's not working properly. I've tried all sorts of variations on it (//node-name, *[name()='node-name'], current-node-name/node-name), but it's still not finding the correct node!
Here's my xml:
<page-reference xmlns="http://something.com">
<relative-path>something/something</relative-path>
<base-path>somePath</base-path>
</page-reference>
I've tried a few different variations of x-paths. Most of them work if I take out the xmlns attribute of the page-reference tag. For example: //relative-path, /page-reference/relative-path, relative-path, page-reference/relative-path
, but none of them work with the xmlns attribute.
Any ideas what could be causing this? I thought that it's the double slash after the http in the value, but I have no idea why that would cause an issue, and it also does not seem to be the case.