popup_menu() (and checkbox_group(), radio_group(), etc) can absolutely simplify your templates, on large forms you'll see a huge difference. Personally I haven't often had the need to edit form fields directly as HTML, because you can apply a class to the field and change much of it's appearance with CSS. Most field options are created off database queries, seldom are select/radio/check lists hardcoded.
I only use CGI.pm to parse values, print headers, handle uploads and create HTML Forms (though I've started to use CGI::FormBuilder for most of my forms). On trivial apps I'll use the HTML generation features, too. For me, I think this is CGI.pm's "highest and best" use- the tricky stuff that doesn't usually impact design is handled by a library that does it EXTREMELY well.
The way I think of it- you can absolutely save yourself time generating the HTML form fields with CGI, and in those cases where you just can't because of some design problem (which is pretty rare, in my experience), you can always fall back to manual form element generation. In the meantime, you've still come out ahead, with smart forms and saved effort.
-Any sufficiently advanced technology is
indistinguishable from doubletalk.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
Outside of code tags, you may need to use entities for some characters:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
| & || & |
| < || < |
| > || > |
| [ || [ |
| ] || ] ||