| urllib2_file | index /Users/buggy/Documents/code/OmixedPythonLibrary/urllib2_file.py |
enable to upload files using multipart/form-data
idea from:
upload files in python:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/146306
timeoutsocket.py: overriding Python socket API:
http://www.timo-tasi.org/python/timeoutsocket.py
http://mail.python.org/pipermail/python-announce-list/2001-December/001095.html
import urllib2_files
import urllib2
u = urllib2.urlopen('http://site.com/path' [, data])
data can be a mapping object or a sequence of two-elements tuples
(like in original urllib2.urlopen())
varname still need to be a string and
value can be string of a file object
eg:
((varname, value),
(varname2, value),
)
or
{ name: value,
name2: value2
}
| Modules | ||||||
| ||||||
| Classes | ||||||||||||||||
|
| ||||||||||||||||
| Functions | ||
| ||
| Data | ||
| CHUNK_SIZE = 65536 | ||