amurarka
Programmer
- Nov 13, 2011
- 3
pls tell me how to monitor url with the help of proxy in perl.
below code is not working plzzz corect it.
use warnings;
use strict;
use LWP::Simple qw($ua get);
$ua->proxy('http','acpwinggn2isa01a.aircel.co.in:80');
my $url = "my $webpage = get $url;
#my $url = get '
if (!$webpage) {
#open OUTPUT, ">>output.txt";
print "ERROR: Could not retrieve $url" ;
print scalar localtime(),"\n";
#close OUTPUT;
}
else {
#open OUTPUT, ">>output.txt";
print "no errors found ";
print scalar localtime(),"\n";
#close OUTPUT;
}
exit(0);
below code is not working plzzz corect it.
use warnings;
use strict;
use LWP::Simple qw($ua get);
$ua->proxy('http','acpwinggn2isa01a.aircel.co.in:80');
my $url = "my $webpage = get $url;
#my $url = get '
if (!$webpage) {
#open OUTPUT, ">>output.txt";
print "ERROR: Could not retrieve $url" ;
print scalar localtime(),"\n";
#close OUTPUT;
}
else {
#open OUTPUT, ">>output.txt";
print "no errors found ";
print scalar localtime(),"\n";
#close OUTPUT;
}
exit(0);