How get a text element from an xpath expression in Selenium?
When Selenium navigates through web pages I want to save some of the text from tha开发者_JAVA技巧t web pages. I use Selenium with Java. So is there a way to extract from that web pages the text having a specific xpath?
selenium.getText("//div[@id='debugState']");
Visit, http://release.seleniumhq.org/selenium-remote-control/0.9.0/doc/java/com/thoughtworks/selenium/DefaultSelenium.html#getText%28java.lang.String%29
精彩评论