$string =~ s/($pattern)/$1$stuffToAdd/g; #### Start | Programs | ActiveState ActivePerl | Documentation