I have, for example, the next XPath query:
//div[span=\"something\"]/parent::div/child::div[@class=\\\"someClass\\\"]
I want to use this XP
if you want to select an element inside an iframe, from parent window, you should change second parameter of evaulate() function to iframe's document element, like :
var iFrameDocument = $('iframe#myPage').get(0).contentWindow.document;
xpathResult = this[0].evaluate(xpathExpression, iFrameDocument, null, XPathResult.ORDERED_NODE_ITERATOR_TYPE, null);