XPath filtering sub node

robbiejlove

New Member
I have a xml contains following information, i am using Xpath to parse the it\[code\]<root> <a> <b></b> <c></c> <d></d> </a> <a> <b></b> <c></c> <d></d> </a></root>\[/code\]my target is to get the nodelist of tag 'a' and in each sub nodelist containing 'b' and 'c' (etc. filter out 'd'!) what I am currently doing is use '/root/a' to get nodes containing all 'a','b' and 'c', then get rid of 'c' afterwards, what I am targeting to do it do the filtering within XPath instead of using extra code, is there anyway I can do it? thanks!
 
Back
Top