This content has been marked as final. Show 4 replies
server side would be:
<cfif NOT structKeyExists(form, 'whichLogin')>
handle error here
client side would be:
1) add an onsubmit="return validate(this);" in your form tag.
2) add the following code block:
Originally posted by: mikeap
I have a form which dynamically spits out my users so they can be assigned to a project. How can I require at least one of the checkboxes that it spits out or is their a better method to my madness?
Instead of check boxes use radio buttons or a select.
but radio buttons or a select (unless the latter has the multiple attribute assigned) would only allow one selection. if I understood correctly (and don't get me wrong, it's a distinct possibility that I don't <g>), the OP wants to make sure at -least- one of the records is chosen (implying that there could be more).
You could use a select allowing for multiple selections but I prefer to use checkboxes because it allows me greater control but I guess it's just a matter of preference.