in reply to Re: HTML::Template : How to separate code and html with lesser maintenance issues
in thread HTML::Template : How to separate code and html with lesser maintenance issues

if ($item eq "SELECT") { $tmpl = "select.tmpl"; } elsif ($item eq "CONTINUE") { $tmpl = "continue.tmpl"; } elsif ($item eq "DENIED"){ $tmpl = "denied.tmpl"; }

In which case (I know you're adapting the OP's code, but) one would probably use a hash instead, especially if other options were possibly to be added. But of course this is just a complete side note.

  • Comment on Re^2: HTML::Template : How to separate code and html with lesser maintenance issues
  • Download Code