I have 10 different pages contain different links. How to click on all the links?
Conditions are : i) I don\'t know how many links are there ii) I want to count and
public static void main(String[] args)
{
FirefoxDriver fd=new FirefoxDriver();
fd.get("http:www.facebook.com");
List links=fd.findElements(By.tagName("a"));
System.out.println("no of links:" +links.size());
for(int i=0;i
This program clicks on a link, navigates back to the page and clicks the second link again.