Aug 22, 2019 in Selenium
Q: What are the different types of navigation commands?

1 Answer

0 votes
Aug 22, 2019
We use Navigate interface to do navigate back and forth in a browser. It has methods to move back, forward as well as to refresh a page.

driver.navigate().forward(); – to navigate to the next web page with reference to the browser’s history

driver.navigate().back(); – takes back to the previous webpage with reference to the browser’s history

driver.navigate().refresh(); – to refresh the current web page thereby reloading all the web elements

driver.navigate().to(“url”); – to launch a new web browser window and navigate to the specified URL

Related questions

0 votes
Aug 19, 2019 in Selenium
0 votes
Aug 19, 2019 in Selenium
...