Hello,
I'm developing an application with java + selenium I have the second web element:
WebElement results = ( new WebDriverWait( driver, timeout ) ).until( ExpectedConditions.visibilityOfElementLocated( By.id( "local" ) ) );
Where id = local is a div that contains an html list of type:
<div id="local">
<ul>
<li>
<span>texto</span>
</li>
<li>
<span>texto</span>
</li>
<li>
<span>texto</span>
</li>
</ul>
</div>
I wanted to extract the text from all. I do not know how to get the li's list with xpath from the div in WebElement. Then I wanted to get a list in java with all li, to iterate and so get every span.
Any ideas how to do it? I do not know how to go get xpath the names I want.
Is it possible to extract all span with xpath at once?
Thank you!