I have a input text box having id property and the HTML for it as shown below
username:<input type="text" id="1234"><br>
Id property is dynamically changing. when the page loads next time.
Username:<input type="text" id="5678"><br>
and the value continuously changing.
how to write the XPath for the above scenario.
Here we have only one ID property no other properties are available. I know we can use contains,starts-with or write absolute XPath helps in other cases.
Please help me on this.
//*[contains(text(),'Username:')]/input