Hi,
We need to post a zip file on HTTP using Python 2.7.
We are using the below code which throwing exception:
Please help.
Thanks and Regards
We need to post a zip file on HTTP using Python 2.7.
We are using the below code which throwing exception:
1 2 3 |
post_data = open (zipPath,u 'rb' ) request = urllib2.Request(url,post_data.read().encode(u 'utf-8' )) request.add_header(u "Content-Type" , u "application/zip" ) |
Thanks and Regards