in reply to eval using hash values
It may be a bit of an overkill, but assuming you are trying to have:
I think Text::Template will do exactly what you want. If that's not what you want, please clarify.$text = 'my $foo has gone completely $bar'; %hash = (foo => 'dog', bar => 'crazy'); $final_text = unknown_method($text); #$final_text is now 'my dog has gone completely crazy'
|
---|
In Section
Seekers of Perl Wisdom