3 ms·
The XPath for the second one would be: //root/item/key[text()="Name"]/../value/text()
by elFarto 7y ago
The XPath for the second one would be:
//root/item/key[text()="Name"]/../value/text()
- icebraining 7y agoAlternatively //root/item[key[text()="Name"]]/value/text()
- benibela 7y agoYou usually do not need to use text() in xpath, so this should work the same: //root/item[key="name"]/value