SHARE
TWEET

Untitled

Krenair Apr 1st, 2012 256 Never
  1. class MyHTTPRedirectHandler(urllib2.HTTPRedirectHandler):
  2.     def redirect_request(self, req, fp, code, msg, headers, newurl):
  3.         request = urllib2.Request(newurl)
  4.         request.get_method = lambda: req.get_method()
  5.         return request
RAW Paste Data
Top