Xpath - node search limit not working?
What am I doing wrong here? I'm trying to limit my xpath search to a specific row in my table, but my query always returns the contents of the range on the first row:
var query = "//span[contains(@id, 'timer')]";
var root = document.getElementById('movements').rows[1];
document.evaluate(query, root, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue.textContent
Please, help!
+2
a source to share