Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
18 lines (16 sloc) 467 Bytes
#!/usr/bin/python
import spynner
import pyquery
browser = spynner.Browser(debug_level=spynner.INFO)
browser.create_webview()
browser.show()
browser.load("http://www.wordreference.com")
browser.choose("input[name=lr=lang_es]")
browser.click("input[name=enit]")
browser.click("a[class=l]:first")
d = pyquery.PyQuery(browser.html)
d.make_links_absolute(base_url=browser.url)
href = d('a:last').attr('href')
print href
print len(browser.download(href))
browser.browse()
Something went wrong with that request. Please try again.