On 2004-10-17, Jonathan Mangin <[EMAIL PROTECTED]> wrote:
>
> HtmlTemplate looked easy enough, but mentions problems with <select>
> constructions. Does TT treat these more gracefully?
There is an easy solution for <select> lists with HTML::Template.
1. If you have the complete list hardcoded, but just need to select a
value--- you can use HTML::FillInForm for that. (Usually when you need
to fill in one form element, you need to fill in the whole form...)
2. If you need to build a completely dynamic list:
Just use CGI.pm's popup_menu() or select() functions.
You'll have code that looks like this:
$t->param(
my_popup => $self->query->popup_menu(
-name => ...
# etc...
),
);
Since HTML folks rarely need to anything with the contents of a <select>
tag, this works fine.
Mark
--
http://mark.stosberg.com/
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/[EMAIL PROTECTED]/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]