as an addendum to the idea that I sent along, you will need to do some
additional work if you are including any checkboxes in your initial form.
Use <CFPARAM NAME="FORM.checkboxname" DEFAULT="defaultvalue"> at the top of
the resulting page to set the checkbox value if the user didn't check it,
and then you will need to do a LISTAPPEND(FORM.fieldnames,"checkboxname") to
include that form name in the field names since CF will not see the checkbox
if it isn't selected, and will not automatically insert the name into the
fieldnames list when you use the CFPARAM.  Just FYI.

-----Original Message-----
From: Alex Santantonio [mailto:[EMAIL PROTECTED]]
Sent: Friday, August 31, 2001 11:57 AM
To: CF-Talk
Subject: RE: fieldnames structure

Loop through the list of field names,
<CFOUTPUT>
<CFLOOP LIST="#FORM.Fieldnames#" INDEX="field">
        <INPUT TYPE="Hidden" NAME="#field#" VALUE="#Evaluate("FORM." &
Field)#">
</CFLOOP>
</CFOUTPUT>
-----Original Message-----
From: Deanna Schneider [mailto:[EMAIL PROTECTED]]
Sent: Friday, August 31, 2001 11:38 AM
To: CF-Talk
Subject: fieldnames structure

Hi Folks,
I'm trying to figure out this structure thing, and I have a project where I
have to grab all the fieldname/value pairs from one form, hold them while
the user fills out a second page, then send them along in a hidden field to
the action page.

What's the best way to do this? I thought I could just do something like:
<input type="hidden" name="page1struct"
value="#structcopy(form.fieldnames)#"> But that throws an error.

-d



Deanna Schneider
Interactive Media Developer
[EMAIL PROTECTED]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to