Problem with proxies

stoyan stoyan.shopov at lisasoft.com
Wed Oct 17 06:22:38 CEST 2007


import urllib2
proxy_support = urllib2.ProxyHandler({'http' :
'username:password at proxyserver:port'})
opener=urllib2.build_opener(proxy_support)
urllib2.install_opener(opener)
print urllib2.urlopen('http://www.python.org').read()

Hi, the above works for me. The hardest part is getting the proxy handler
values right. 

Cheers, 
Stoyan. 
-- 
View this message in context: http://www.nabble.com/Problem-with-proxies-tf4634878.html#a13246881
Sent from the Python - python-list mailing list archive at Nabble.com.




More information about the Python-list mailing list