Your example has:
open (INNEWSFILE, $inFile);
...
$newsFile = <INNEWSFILE>;
$newsFile =~ s/<B>//g;
That second line only reads the first line of the infile. That's why the
rest of it never gets written to the outfile.
You may find it more helpful to slurp the whole file into a scalar variable
there:
$newsFile = join "\n", (<INNEWSFILE>);
Or you could loop on the filehandle with
while ($_ = <INNEWSFILE>) {
#substitute
#print to outfile
}
I am subscribed to the digest version of this list so write directly to me
if you want a quick reply.
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.