in reply to HTML::Template Modules and Zeros
When in doubt, write a short test.
produces the expected resultuse HTML::Template; # version 2.6 my @template = <DATA>; my $template = HTML::Template->new(arrayref => \@template); $template->param(ZERO => 0); $template->param(ONE => 1); print $template->output(); __DATA__ Zero = <TMPL_VAR ZERO> One = <TMPL_VAR ONE>
You might have run into a version-dependent bug, or you might have a problem upstream. What happens when you try to replicate the problem with a small example?Zero = 0 One = 1
Update: jeffa points out that
my $template = HTML::Template->new(filehandle => *DATA);
is another way to go.
|
|---|