I am trying to extract an element with specific inner text from a parsed XML document. I know that I can select an element that has a child with a specific inner text using //myparent[mychild='foo'] , but I just want to select the “mychild” element in this example.
<myparent> <mychild> foo </mychild> </myparent>
What will be the XPath query for "foo" that will return a "mychild" node?
xml xpath
kdt Jan 04 2018-10-10T00: 00-01
source share