How about an even simpler version, using my new favorite module WWW::Mechanize?
#!/usr/bin/perl -w use strict; use WWW::Mechanize; my $agent = WWW::Mechanize->new(); $agent->get('http://cnn.com/'); foreach (@{$agent->links()}) { print "LINK:".URI->new($_->[0])->abs($agent->base())."\n"; }
| We're not surrounded, we're in a target-rich environment! |
|---|
In reply to Re: LWP::NOT so simple
by jasonk
in thread LWP::NOT so simple
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |