Perl Home Notes Exercises Resources perl Thoughts Jen's Home Summer Perl Seminar

LWP

LWP is a perl module for accessing web pages. It provides you with a bunch of functionality to easily retrieve things from the web. You will want it for everything we do in class.

If you downloaded ActivePerl for windows, LWP should have automatically come with it. If you have a mac or unix machine, you may need to install it. To test if you have it, download this perl script and run it. If it works, it will print a happy message. If it doesn't work, you will see an ugly message.

If you are on a Mac or unix machine and need to install lwp, you can download it from cpan. Cpan is a website that lists tons of perl resources and provides you with the code. On the cpan page, to the right you will see a link to Download: libwww-perl-5.812.tar.gz. Click that to download and save it to your Desktop. Expand the file (this probably will happen automatically, but if not, double click it). Then, open the terminal (Applications->Utilities->Terminal), and type the following list of commands, followed by a return on each line.

cd Desktop/libwww-perl-5.812 perl Makefile.PL make make test make install It will print out lots of stuff. You really just care if it ends up ok or with an error. When you are done, try running that test file again. Email me if you have any questions.