Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
I'm trying to create nested loops with HTML::Template and have run into some difficulty. I have template data like so:
<TMPL_LOOP NAME=SECTION_NAMES> <p><b><input type="radio" name="section" value="<TMPL_VAR SECTION_ +NAME>" /><TMPL_VAR SECTION_NAME>:</b></p> <TMPL_LOOP NAME=SUB_SECTION_NAMES> <blockquote><input type="radio" name="subSection" value="<TMPL +_VAR NAME=SUB_SECTION_NAME>" /><TMPL_VAR NAME=SUB_SECTION_NAME></bloc +kquote> </TMPL_LOOP> </TMPL_LOOP>
And I have a Hash of arrays in the form {SECTION_NAME}[SUB_SECTION_NAMES].
I've read the docs but I can't seem to grasp how I'd go about feeding this data to HTML::Template. Is this possible, or do I need a HoH?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Nested HTML::Template Loops
by ViceRaid (Chaplain) on Jun 25, 2003 at 11:09 UTC | |
by Anonymous Monk on Jun 25, 2003 at 11:45 UTC | |
by bwana147 (Pilgrim) on Jun 26, 2003 at 10:09 UTC |