- or download this
$ ./1.lwp.pl
execution here
execution there
...
say "execution there";
__END__
$
- or download this
# Set up configuration data
use vars qw{%SUPPORTED @RELIABLE_HTTP};
BEGIN {
...
'http://cnn.com/' => sub { /CNN/
+ },
);
}
- or download this
use LWP::Simple 5.805 qw{ get $ua };
use vars qw{$VERSION @ISA @EXPORT_OK};
...
# Set the useragent timeout
$ua->timeout(30);
}
- or download this
sub get ($)
{
my $response = $ua->get(shift);
return $response->decoded_content if $response->is_success;
return undef;
}