Quantcast
Channel: PTC Community : All Content - Arbortext
Viewing all articles
Browse latest Browse all 1645

XPath Question

$
0
0

Dear Users

 

I am looking for a solution to frame xpath logic to compare attributes.


<menucontainerid="menu1"op="o3"indicator="highlight">
<menubox>
<menutitle>TITLE</menutitle>
<menuoptionlist>
<menuoptionid="o1">Select a path from below :</menuoption>
<menuoptionid="o2">IMAGE1</menuoption>
<menuoptionid="o3">IMAGE2</menuoption>
<menuoptionid="o4">IMAGE3</menuoption>
<menuoptionid="o5">IMAGE4</menuoption>
<menuoptionid="o6">IMAGE5</menuoption>
</menuoptionlist>
</menubox>
</menucontainer>


Here I want to compare menucontainers op value (op="03") against the menuoption id's.So here the ideal match would be IMAGE2. And I would be highlighting the IMAGE2 in red colour.

I tried //menublock/menucontainer/@op= //menublock/menucontainer/menuoptionlist/menuoption/@id

but it is not dynamic.It checks first result and applies the same result everywhere.pls help in framing the xpath .

 

pls help

 

Regards,

Sriram Rammohan


Viewing all articles
Browse latest Browse all 1645

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>