Get Current URL using Selenium WebDriver (Python)
To get the current page's URL, use the WebDriver attribute current_url like so:
url = self.driver.current_url print(url);
This example will store the URL into a variable and print it to the console.
Leave a reply
Your email address will not be published. Required fields are marked*