use strict; use warnings; use HTML::Template; my $html = < >
HTML my $tmpl = HTML::Template->new(scalarref => \$html); my @loopParams = ( {index => 1, filename => 'plonk', check => 'f1'}, {index => 2, filename => 'pip', check => 'f2'} ); $tmpl->param(files_loop => \@loopParams); print $tmpl->output(); #### 1 plonk 2 pip