views:

66

answers:

1

I'm trying to use WWW::Mechanize with a proxy server, but seems like I cant get it to work. Since Mechanize is a subclass of LWP::UserAgent, I've been reading about the proxy thing over link text

I have a list of proxies, for example:

74.87.151.157:8000  
69.171.152.25:3128  
190.253.82.253:8080 
189.11.196.221:3128 
41.234.205.201:8080

I have no idea how to use them.

Thanks,

+1  A: 

This example sets a HTTP-proxy:

my $mech  = WWW::Mechanize->new();
my $proxy = '74.87.151.157:8000';

$mech->proxy('http', "http://$proxy");
eugene y
When I use this method I get error: Error GETing http://www.google.com: Not Found at ./my-script.pl line 63
jesper