I would have done it like that :
undef $/; # to absorb the whole file in a single read. open FILE, $filename; $all = <FILE>; $all =~ s/\.html/\.asp/g; # this will substitue the .html to .asp glob +ally # this takes the part in between the body tags... $all =~ s{^.*?\<body.*?\>(.*)\</body.*?\>.*?$} {$1}isx; print OUTFILE $all; close FILE;
In reply to Re: Removing duplicate line
by Chady
in thread Removing duplicate line
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |