Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
#!/usr/bin/perl use HTML::LinkExtor; use URI::URL; if ($#ARGV != 0 ) { print "usage: linkextractorfile.pl file\n"; exit; } $file=$ARGV[0]; print "$file\n"; my $p = HTML::LinkExtor->new(); $p -> parse ($file); my @links = $p->links(); # Print them out foreach (@links) { print "$_\n"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Extracting links from files
by Anonymous Monk on May 14, 2010 at 06:30 UTC | |
by Anonymous Monk on May 14, 2010 at 06:46 UTC |