Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handling multiple window or pop-ups #91

Open
zero-master opened this issue Nov 2, 2016 · 3 comments
Open

Handling multiple window or pop-ups #91

zero-master opened this issue Nov 2, 2016 · 3 comments

Comments

@zero-master
Copy link

In Selenium, we 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 a 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)

Is there any way to do it with Splash/Scrapy?

@kmike
Copy link
Member

kmike commented Nov 2, 2016

No, multiple windows and non-js poopups are not supported by Splash at the moment.

@zero-master
Copy link
Author

Thank you for the response.

Since you've emphasized that it doesn't work with "non-js popups".

Could you please tell me how I can handle JS popups? Just need some clues.

@kmike
Copy link
Member

kmike commented Nov 2, 2016

I just meant that some popups are implemented as <div> elements over the webpage, as opposed to opening a new browser window, and you can work fine with these popups.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants