Comments (4)
I looking for a an answer to this, additionally - mine deals with selecting multiple checkboxes.
from robobrowser.
I gave up and I started using Selenium for Firefox. It requires a .xml file where you mention actions. And I generated this xml file from python script and ran the whole thing with selenium.
from robobrowser.
Sorry for the delay on this! I just added some examples to the README on this, which I'm including here too.
from robobrowser import RoboBrowser
# Browse to a page with checkbox inputs
browser = RoboBrowser()
browser.open('http://www.w3schools.com/html/html_forms.asp')
# Find the form
form = browser.get_forms()[3]
form # <RoboForm vehicle=[]>
form['vehicle'] # <robobrowser.forms.fields.Checkbox...>
# Checked values can be get and set like lists
form['vehicle'].options # [u'Bike', u'Car']
form['vehicle'].value # []
form['vehicle'].value = ['Bike']
form['vehicle'].value = ['Bike', 'Car']
# Values can also be set using input labels
form['vehicle'].labels # [u'I have a bike', u'I have a car \r\n']
form['vehicle'].value = ['I have a bike']
form['vehicle'].value # [u'Bike']
from robobrowser.
Just tried it out, works!
Have to say, this is an elegant interface. Thanks.
from robobrowser.
Related Issues (20)
- cannot use
- .csv file getting record empty
- Unmaintained, dead, list of alternative projects
- Error handling detected unusual traffic
- browser cookies dont get changed HOT 1
- Import Error: HTMLParser HOT 1
- page screenshot
- Is this project abandonned ? HOT 1
- ImportError: cannot import name 'RoboBrowser' HOT 3
- Cannot set a value to non-existent attribute within a field
- Remove Checkbox in form
- Broken on Python 3.7 - access to re._pattern_type in Browser.get_link() HOT 1
- How to click a button in form HOT 2
- About retry
- Refresh page
- Inaccurate Docs
- RoboBrowser is broken with werkzeug upgrade HOT 4
- download
- pls fix the 'werkzeug' library HOT 8
- Possible to upload multiple files? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from robobrowser.