Re: LOOPING error [code included]

Benjamin Warfield <[email protected]> Tue, 5 Dec 2006 22:18:06 -0500
Newsgroups gmane.comp.lang.perl.modules.html-template
Message-ID <[email protected]>
On Dec 5, 2006, at 9:44 AM, Michael Peters wrote:
> Setting die_on_bad_params to false will let you get around this  
> problem, but that causes
> problems if you wanted strict templates in the first place.

You can also get around the problem without disabling variable-name  
checking for the rest of the template, albeit in a remarkably hackish  
way: just add the appropriate version of

<TMPL_IF NAME="my_missing_var"></TMPL_IF>

on the inside of the loop that doesn't actually make use of the  
variable, and it will show up as a valid variable for both loops.

	--Ben Warfield

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV