Hi, I need one complete example of how to do a http post to any site. I have tried making a POST to google but all I am returned with is a 405 error. I don't want to use Pygoogle as I want to try and do this with other sites. I am also having problems inputing with the param I have tried Mechanize. There are no problems with getting data only posting.
>>> headers = {'Content-Type': 'text/html; charset=ISO-8859-1', ... 'User-Agent':'Mozilla/4.0', ... 'Content-Length':'7'} >>> conn = httplib.HTTPConnection("www.google.com") >>> conn.request("POST","/search",params,headers) >>> r2 = conn.getresponse() >>> print r2.status, r2.reason 405 Method Not Allowed Regards, Dhaval -- http://mail.python.org/mailman/listinfo/python-list