hpvic03
Technical User
- Aug 2, 2006
- 89
I have a page that generates a form with dynamically named checkboxes. I need a way to figure out which check boxes were checked. Anyone know of a way to do this?
Just think of a simple database of names:
John
Joe
Frank
Fred
Alex
Each name has a checkbox next to it. There is a submit form at the bottom. Which names were checked?
The checkboxes are named after each person. So I thought of just looping through the database to see if each name was checked,
<cfoutput query="namelist">
<cfif form.#name# is "checked"> -- code -- </cfif>
</cfoutput>
But apparently you can't do form.#name#. So I don't know where to go from there. Thanks in advance!
Just think of a simple database of names:
John
Joe
Frank
Fred
Alex
Each name has a checkbox next to it. There is a submit form at the bottom. Which names were checked?
The checkboxes are named after each person. So I thought of just looping through the database to see if each name was checked,
<cfoutput query="namelist">
<cfif form.#name# is "checked"> -- code -- </cfif>
</cfoutput>
But apparently you can't do form.#name#. So I don't know where to go from there. Thanks in advance!