I either check the form scope:
<cfif StructKeyExists( FORM, "your_checkbox" )>
<!--- Submitted. --->
<cfelse>
<!--- Not submitted. --->
</cfif>
Mostly though, I default the form variable to a default value and then I
assume the check box would set the non-default value:
<cfparam name="FORM.your_checkbox" type="numeric" default="0" />
Then the checkbox value would be 1 and I could do:
<cfif FORM.your_checkbox>
<!--- Submitted. --->
<cfelse>
<!--- NOT submitted. --->
</cfif>
......................
Ben Nadel
Certified Advanced ColdFusion MX7 Developer
www.bennadel.com
Need ColdFusion Help?
www.bennadel.com/ask-ben/
-----Original Message-----
From: John Eubanks [mailto:[EMAIL PROTECTED]
Sent: Monday, February 12, 2007 12:26 PM
To: CF-Newbie
Subject: Checkbox Question
Quick question: I have a checkbox on a form. What is the easiest way
to check and see if it is checked, and if so, process the value.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Upgrade to Adobe ColdFusion MX7
Experience Flex 2 & MX7 integration & create powerful cross-platform RIAs
http:http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU
Archive:
http://www.houseoffusion.com/groups/CF-Newbie/message.cfm/messageid:2518
Subscription: http://www.houseoffusion.com/groups/CF-Newbie/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15