in reply to How to check value of checkbox on form submit?
Checkboxes don't have values unless you give them one. If they are checked, the name=value pair is sent. Otherwise, IIRC, nothing is sent. So in your HTML, you need:
When you receive your form input, "blort" will equal "foo" if checked. If it isn't checked, "blort" will be undefined.<input type="checkbox" name="blort" value="foo">
|
---|
Replies are listed 'Best First'. | |
---|---|
RE: Re: How to check value of checkbox on form submit?
by BBQ (Curate) on May 10, 2000 at 19:07 UTC | |
by perlmonkey (Hermit) on May 10, 2000 at 23:22 UTC | |
by raflach (Pilgrim) on May 10, 2000 at 19:14 UTC | |
by BBQ (Curate) on May 10, 2000 at 19:21 UTC |
In Section
Seekers of Perl Wisdom