Logo Search packages:      
Sourcecode: nautilus-image-manipulator version File versions  Download package

def nautilus_image_manipulator::upload::poster::encode::get_headers (   params,
  boundary 
)
Returns a dictionary with Content-Type and Content-Length headers
for the multipart/form-data encoding of ``params``.

Definition at line 305 of file encode.py.

                                 :
    """Returns a dictionary with Content-Type and Content-Length headers
    for the multipart/form-data encoding of ``params``."""
    headers = {}
    boundary = urllib.quote_plus(boundary)
    headers['Content-Type'] = "multipart/form-data; boundary=%s" % boundary
    headers['Content-Length'] = str(get_body_size(params, boundary))
    return headers


Generated by  Doxygen 1.6.0   Back to index