Something like:

update blah where something set (
<cfif isdefined("form.status")>
   Status,
</cfif>
....
values (
<cfif isdefined("form.status")>
  1
<cfelse>
  0
</cfif>
....

Basically, if the form field exists then the user has checked the box.

HTH,

Howie Hamlin - inFusion Project Manager
On-Line Data Solutions, Inc.
www.CoolFusion.com
631-737-4668 x101
inFusion Mail Server (iMS) - The Intelligent Mail Server
Join the DevCon community at www.coolfusion.com/devcon

----- Original Message ----- 
From: "Jones, Becky" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Tuesday, July 03, 2001 4:19 PM
Subject: checkboxes


> i have a form that has a list of articles. and next to each article there is
> a checkbox. and it displays that it is checked like so:
> <input type="Checkbox" name="Status" <cfif #status# eq 1>checked</cfif>
> value="1">
> if the article is "live"
> does anyone know how i would write the update statement?  ive tried
> everything, and i cant get it to work.
> thanks,
> bec.
> 
> 
> *************************************************
> This e-mail, including any attachments, is intended for the 
> receipt and use by the intended addressee(s), and may contain 
> confidential and privileged information.  If you are not an intended 
> recipient of this e-mail, you are hereby notified that any unauthorized 
> use or distribution of this e-mail is strictly prohibited. 
> 
> 
> 
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to