Reputation: 887
I'm trying to write a single XPath line that conditionally uses 1 of 2 attribute values depending if one attribute has no value.
Ex.
The logic I'm looking for is...
if @src="" then use @other.
Edited to include that I'm stuck with XPath 1.0.
Upvotes: 0
Views: 84
Reputation: 887
I found a solution that worked for me.
In a nutshell...
concat(../@src,../@other[not(/root/@part_no)])
Upvotes: 1