my $template = HTML::Template->new(filename => $file); # loop füllen my $loop = [{name => 'herbert', nachname => 'müller'},{name => 'lisbeth', nachname => 'müller'}]; # 'normale' variablen my $test = 'dies'; my $ist = 'ist'; # erstellen des Hashs my %params_fuer_template = (MY_LOOP => $loop, VAR_1 => $ist, VAR_2 => $test); $template->param(\%params_fuer_template);