MultipartPostHandler for pyhton 2
sergiomb2/MultipartPostHandler2
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
master
Could not load branches
Nothing to show
Could not load tags
Nothing to show
{{ refName }}
default
Code
Latest commit
Git stats
Files
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
MultipartPostHandler2 ===================== MultipartPostHandler for pyhton 2 Usage: Enables the use of multipart/form-data for posting forms Inspirations: Upload files in python: http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/146306 urllib2_file: Fabien Seisen: <fabien@seisen.org> Example: import MultipartPostHandler, urllib2 opener = urllib2.build_opener(MultipartPostHandler.MultipartPostHandler) params = { "username" : "bob", "password" : "riviera", "file" : open("filename", "rb") } opener.open("http://wwww.bobsite.com/upload/", params) Further Example: The main function of this file is a sample which downloads a page and then uploads it to the W3C validator.
About
MultipartPostHandler for pyhton 2
Resources
Stars
Watchers
Forks
Packages 0
No packages published