Hi All,
I am new user to ttk, I need to process aa mail text for different people in
a loop
but I am getting only first value of that loop, I seen in Template::Manual,
Template::Stash, Template::Context, ...
tried, but not getting solution.
Here is the simple program text,
================================\/================================
#!/bin/env perl
use Template;
our $template = Template->new();
our $txt,
our %var;
foreach ( qw/ a b c d e f / ) {
$var{"x"} = $_;
$template->process(\*DATA, \%var, \$txt);
print "value expected ", $_, "\n";
print $txt;
}
__END__
value really comming [% x %]
================================/\================================
I am getting output
value expected a
value really comming a
value expected b
value really comming a
......
value expected f
value really comming a
I want it
value expected a
value really comming a
value expected b
value really comming b
......
value expected f
value really comming f
Please help to tell how I can get this correct or desired.
--
Regard,
Sharad
_______________________________________________
templates mailing list
[email protected]
http://mail.template-toolkit.org/mailman/listinfo/templates