Help for this page

Select Code to Download


  1. or download this
    use URI::Find;
    
    my $text = "alot of HTML";
    ...
     print $orig_uri,"\n";
     return $orig_uri;
    });
    
  2. or download this
    use HTML::SimpleLinkExtor;
    
    my $extor = HTML::SimpleLinkExtor->new();
    ...
    $extor->parse($html);
    #extract all of the links
    @all_links   = $extor->links;
    
  3. or download this
    require HTML::LinkExtor;
     $p = HTML::LinkExtor->new(\&cb, "http://www.perl.org/");
     sub cb {
    ...
         print "$tag @{[%links]}\n";
     }
     $p->parse_file("index.html");