js get element by xpath code example
Example 1: print element by xpath javascript
document.evaluate('XPATH HERE', document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue;
Example 2: javascript get element by id
var myElement=document.getElementById("someElementID");