#!/usr/bin/perl use strict; use warnings; use LWP::Simple; use HTML::LinkExtor; my $url = 'http://www.perl-community.de/'; my $content; sub connect { $content = get($url); open(FH,">index.html"); print FH $content; close(FH); } sub cb { my($tag, %links) = @_; print %links , "\n"; } &connect(); my $p = HTML::LinkExtor->new(\&cb); $p->parse_file("index.html");