XPath - select text after certain node
25,010
Try this:
//foo/following-sibling::text()[1]
(replace //foo/
with your current XPath expression.
With this XML:
<data>
<foo>foo</foo>
bar
<baz>baz</baz>
</data>
it gives bar
as output.
Author by
warvariuc
An engineer who cares about what he does and how he does it.
Updated on November 27, 2020Comments
-
warvariuc over 3 years
I have found a node, now i need to select sibling text after it:
In my case i need to get the text
: 10 January
How do i do this?