can i use xpath to set element properties ?
/html/body/form[@id='search']/select[@name='category' and @value='apple' and @type='select-one']
can i use xpath to set element properties ?
/html/body/form[@id='search']/select[@name='category' and @value='apple' and @type='select-one']
No, but once you find the element you're looking for, you can set its properties by other means.
XPath, the XML Path Language, is a query language for selecting nodes from an XML document.
To set the value you can use something like a DOM parser and setAttribute('value', 'foo');
It might help if you actually told us if that returned anything or not. You can use count() to see if it returns anything, if not noticeable.