I want to press a button on a site, the following code works on google or youtube websites, but on the
The text base HTML:< div >Login</ div>
CodePudding user response:
try this one
(By.XPATH, '//*[@]')
CodePudding user response:
Try the below xpath
"//*[normalize-space(text())='Login']"
Or
"//*[contains(text(),'Login')]"
Also, provide the more info to understand the question clearly.