Re: python php/html file upload issue

2009-03-22 Thread Gabriel Genellina
En Sat, 21 Mar 2009 11:47:36 -0300, S.Selvam Siva s.selvams...@gmail.com escribió: I want to upload a file from python to php/html form using urllib2,and my code is below See the Python Cookbook: http://code.activestate.com/recipes/langs/python/ -- Gabriel Genellina --

python php/html file upload issue

2009-03-21 Thread S.Selvam Siva
Hi all, I want to upload a file from python to php/html form using urllib2,and my code is below PYTHON CODE: import urllib import urllib2,sys,traceback url='http://localhost/index2.php' values={} f=open('addons.xcu','r') values['datafile']=f.read() #is this correct ? values['Submit']='True' data