Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

Re^3: HTML::Template with checkbox

by GrandFather (Sage)
on Sep 05, 2012 at 23:34 UTC ( #991972=note: print w/ replies, xml ) Need Help??

in reply to Re^2: HTML::Template with checkbox
in thread HTML::Template with checkbox

Oh, silly me. You don't provide a value attribute for your checkbox so nothing gets returned. You need something like:

<td><input type="checkbox" name="field" value="<TMPL_VAR NAME="fi +lename">">

for your checkbox line. That will return the file name if the checkbox is checked.

True laziness is hard work

Comment on Re^3: HTML::Template with checkbox
Download Code
Replies are listed 'Best First'.
Re^4: HTML::Template with checkbox
by bebewinla (Novice) on Sep 06, 2012 at 00:34 UTC

    how do you fetch the checkbox value ? I tried using q->param("field") it returns nothing, do you think the associate => $q is wrong when creating new template. should I take it out, but then how do I fetch the checkbox values

    $q = new CGI; $template = HTML::Template->new(filename => "$displaypage", associate => $q);

      Hope you got the answer by this time now

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://991972]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (7)
As of 2015-10-09 07:24 GMT
Find Nodes?
    Voting Booth?

    Does Humor Belong in Programming?

    Results (234 votes), past polls