Question
CFPARAM How to?
I'm trying to find out if this is possible with the
<cfparam> tag.
One Column Table (my_table)
my_column
a
b
c
d
.
.
z
This table is read to produce an a web page with <input type="radio" name="#my_column#" value="No" /> <input type="radio" name="#my_column#" value="Yes" /> for all the values of the table.
So, the value of the column is the name of the <input> tag.
<input type="radio" name="a" value="No" />
<input type="radio" name="a" value="Yes" />
<input type="radio" name="b" value="No" />
<input type="radio" name="b" value="Yes" />
<input type="radio" name="c" value="No" />
<input type="radio" name="c" value="Yes" />
.
.
etc
Now the question. On the calling page, is there a way to loop through the table and retrieve the value of No/Yes for each value in the table? Meaning, I loop through a..z but retrieve the value of No/Yes for form.A, form.B, form.C, form.D since that's the name of the input tag.
<cfloop query="my_table">
<cfif IsDefined("form."& my_column)> (form.a, form.b, form.c....form.z)
print the value of "a" which should be either No or Yes
</cfif>
</cfloop>
One Column Table (my_table)
my_column
a
b
c
d
.
.
z
This table is read to produce an a web page with <input type="radio" name="#my_column#" value="No" /> <input type="radio" name="#my_column#" value="Yes" /> for all the values of the table.
So, the value of the column is the name of the <input> tag.
<input type="radio" name="a" value="No" />
<input type="radio" name="a" value="Yes" />
<input type="radio" name="b" value="No" />
<input type="radio" name="b" value="Yes" />
<input type="radio" name="c" value="No" />
<input type="radio" name="c" value="Yes" />
.
.
etc
Now the question. On the calling page, is there a way to loop through the table and retrieve the value of No/Yes for each value in the table? Meaning, I loop through a..z but retrieve the value of No/Yes for form.A, form.B, form.C, form.D since that's the name of the input tag.
<cfloop query="my_table">
<cfif IsDefined("form."& my_column)> (form.a, form.b, form.c....form.z)
print the value of "a" which should be either No or Yes
</cfif>
</cfloop>
