in reply to regex substitution

Hi,

If you are into a heavy duty Text pre-processor, you could use Text::Vpp.
It allows you even such fancy things like perl code being processed while you are doing your preprocessing which will give you the possibility of doing things like:

if($gender == 'f') { Dear Mrs. $name, } else { Dear Mr. $name, } we would like to invite you...
We´re using this module for text-preprocessing of TeX-Files for mass printing of letters to our customers. You cannot get it much more flexible and powerfull than that.

Bye
 PetaMem