#! /usr/bin/perl -sw use strict; use warnings; #use URI; use HTML::LinkExtor; local ($^I, @ARGV)=('.bak', glob("/data/loc/text/*.txt")); while (<>){ my $extor = HTML::LinkExtor->new(); next if (my @all_links=$extor->links); print; close ARGV if eof; }