我无法提取正确的 xpath ,可以帮助我

http://img.mukewang.com/643fa7840001500a14740692.jpg

对于 xpath 请帮我获取 xpath



德玛西亚99
浏览 107回答 2
2回答

月关宝盒

尝试 //a[@class='registrationBtn']/span[1]

千巷猫影

要处理动态元素,请引入WebDriverWait并等待元素elementToBeClickable然后单击。试试下面的代码。WebDriverWait wait = new WebDriverWait(driver, 30);WebElement element = wait.until(ExpectedConditions.elementToBeClickable(By.xpath("//div[@class='fr mt-header']/a[@class='registrationBtn' and @title='Client-Patient Registration']")));element.click()或者WebDriverWait wait = new WebDriverWait(driver, 30);WebElement element = wait.until(ExpectedConditions.elementToBeClickable(By.xpath("//div[@class='fr mt-header']/a[@class='registrationBtn' and @title='Client-Patient Registration']/span[@class='reg_icon']")));element.click()
打开App,查看更多内容
随时随地看视频慕课网APP

相关分类

Java