in reply to Module for Perl's "here-is" text formatting

What you're probably looking for is a way to load data into your template from variables. But you're going about this the wrong way. Use a hash to store the data, and regex to substitute:
use strict; use warnings; my %vars = ( var1 => 'MyValue', ); my $here_is = <<SOME_TEXT; I want to print something with a value %var1% and some other text load etc etc SOME_TEXT $here_is =~ s/%(\w+?)%/$vars{$1}/g; print $here_is;
You may also want to look at loading the template from a file or __DATA__, so you're not forced to allow the extra line break that <<TAG makes mandatory.