I've just installed ActivePerl on a windows 2000 machine. When I run "c:\perl -v" it returns v5.8.4. If I run "c:\perl -MLWP -le "print(LWP->VERSION)" it returns 5.79. And when I run "c:\perl -MURI -le "print $URI::VERSION" it returns 1.30.
However, when I run the following program:
my $browser = LWP::UserAgent->new();
my $response = $browser->get("http://www.oreilly.com/
(from the book "Perl & LWP") I receive the following error:
"c:\perl -w example.pl"
Can't locate object method "new" via package "LWP::userAgent" (perhaps you forgot to load "LWP::userAgent"?) at example.pl line 7
If I change the code to "use LWP::UserAgent;" I still get the same error.
Could it be a path problem perhaps?