My XML looks like the below one. I want to check the value of 'number' when //book//genre/text()='classic' , i want to return both 1000 and 1003. Can anybody help please?
<list>
<book>
<author>
<name>John</name>
<number>1000</number>
</author>
<otherDetails>
<genre>classic</genre>
<price>$50</price>
</otherDetails>
<title>Dusk</title>
<isbn>dsdaassda</isbn>
</book>
<book>
<author>
<name>MARK</name>
<number>1001</number>
</author>
<otherDetails>
<genre>comedy</genre>
<price>$140</price>
</otherDetails>
<title>Midnight</title>
<isbn>dsdaassda</isbn>
</book>
<book>
<author>
<name>Pete</name>
<number>1003</number>
</author>
<otherDetails>
<genre>classic</genre>
<price>$140</price>
</otherDetails>
<title>Morning</title>
<isbn>EFGH</isbn>
</book>