How to switch to new window in Selenium for Python?
You can do it by using window_handles and switch_to.window method. Before clicking the link first store the window handle as window_before = driver.window_handles[0] after clicking the link store the window handle of newly opened window as window_after = driver.window_handles[1] then execute the switch to window method to move to newly opened window driver.switch_to.window(window_after) and similarly … Read more