Re: checkboxes & radio button with cfmail
[q][i]Originally posted by: [b][b]JRLobdell[/b][/b][/i]
Yes it does work with 1 checkbox but if there is more that one checkbox I get
the error even though it is defined in cfparam. What csuses this and do you
know hoe I can correct it?
The cause is that when html forms are submitted, any unchecked checkboxes or
radio buttons will not be included in the submission. On your action page,
form.checkbox_field simply won't exist.
There are a variety of solutions. They include:
On your form, precede each checkbox with a hidden field of the same name.
Then on your action page, use the listlast() function.
Use cfparam on your action page for every checkbox and radio button
Use isDefined() on your action page for every checkbox and radio button