matija and duff
Many thanks for your replies. I got it working using duff's
solution.
The local *FH stuff I think I picked out from Programming
Perl or some where on the net. Not sure.
Anyway, I changed it as described in the solution.
One thing I'm still confused about are the m and s modifiers.
Still don't understand:
/m matches ^$ next to embedded \n
-- not sure what this means
/s . match newline and ignores deprecated $*
-- same here, not sure what this means
Anyway, thanks both for replying and getting my script
working!!!
OK, ok, ok...I understand now....
I re-read http://www.infocopter.com/perl_corner/perlre.htm
and http://lists.w3.org/Archives/Public/public-qt-comments/2003Jul/0091.html
I also got both solutions working. Here is majita's
solution which I just figured out: