Automate File Download From Http Using Python
I want to automatically save a file from a website. I don't know how to bypass the Download File prompt in python and save it directly to my c: drive. Any help is appreciated, Elli
Solution 1:
Modules like urllib2
and urlgrabber
don't have a "Download File" prompt.
Solution 2:
One idea is to use a module like mechanize to automate the query and the download. Here you can find some documentation.
- Usually when you post a question here at stackoverflow, it is a good idea to post an example at how you have tried to solve the problem, and then we will help you to improve it, rather than asking people to write the solution for you,
- when you use mechanize, configure the UserAgent properly and respect the policy of the webmasters about scraping.
Post a Comment for "Automate File Download From Http Using Python"