#! perl\bin\perl use strict; use warnings; use WWW::Mechanize; my $mech = WWW::Mechanize->new(); open(FILE, "< file1.html") || print "Unable to open the file file1 \n"; while () { for my $l ($mech->links) { my $url = $l->url; my $desc = $l->text; my $new = $url; $new =~ s/on\.fe/arax.com/; print "concerning $desc, $url should be $new\n"; # $mech->get( $new ); } } close(FILE);