You are looking at a very old, but free version of the course. If you are interesed the most recent version, check it out on the Perl Maven site.

8.11. LWP

Example 8-9. examples/network/

use strict;
use warnings;

my $url = 'http://localhost/';
if (defined $ARGV[0]) {
    $url = $ARGV[0];
use LWP::UserAgent;
my $ua = LWP::UserAgent->new;
$ua->agent("Internet Explorer/17.1");
my $req = HTTP::Request->new(GET => $url);

my $res = $ua->request($req);

if ($res->is_success) {
    print $res->content;
} else {
    print $res->status_line, "\n";

If you are interested in on-site trainings by the author, please contact me directly.