* est <[EMAIL PROTECTED]> [2007-07-23 09:50:17]:
> A simple py script
>
> import urllib2
> req=urllib2.Request("http://www.google.com";)
> req.set_proxy("127.0.0.1:1","http")
> print urllib2.urlopen(req).read()
>
Try to use the ProxyHandler of urllib2.
import urllib2
proxy_url = 'http://' + PR
A simple py script
import urllib2
req=urllib2.Request("http://www.google.com";)
req.set_proxy("127.0.0.1:1","http")
print urllib2.urlopen(req).read()
Here is error:
"C:\Python25\python.exe" -u "E:\Python\Crawler\test.py"
Traceback (most recent call last):
File "E:\Python\Crawler\test.py"