Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

How to get next Page Html

18 views
Skip to first unread message

Tom Kennedy

unread,
Feb 15, 2017, 10:36:42 AM2/15/17
to splinter-users
This is my first week with Splinter.

I want to traverse a website to perform some automation.
I have the following code.
browser=Browser()
browser.visit(url)
browser.find_by_id('j_username').fill(curid)
browser.find_by_id('j_password').fill(curpwd)
browser.find_by_id('button.ok').first.click()
print browser.html

It logs in to the URL just fine and I can see a link I want to click labeled 'Change Passwords'
FWIW, the page has several frames on it.

If I do browser.find_by_text('Change Passwords'), it fails.
The output from print browser.html shows the html form the original url.
I expect that the html  in the browser would be that returned after the  OK button is clicked.
Am I missing something here?




Tom Kennedy

unread,
Feb 15, 2017, 11:07:45 AM2/15/17
to splinter-users
OK, I was looking at an example and see that they put in sleep after click, to wait for new html is returned.
So, I get that.  But I still cannot find the Change Passwords text, even though I see it in the browser.

Tom Kennedy

unread,
Feb 15, 2017, 12:19:05 PM2/15/17
to splinter-users
Looks like I need to do this:
frame=browser.get_iframe('taskbar_area') to get the frame.
Are the functions supported on  a frame documented anywhere?
Reply all
Reply to author
Forward
0 new messages