sample and source can be found here.
http://www.theparadox.com/formreuse/



At 12:08 PM 4/16/2002 -0500, you wrote:
>I have tried many different form reuse techniques, and have found the one 
>I like best and thought I would share it with all.
>
>this is the overview of the process, let me know if you would like code 
>samples or further explanation.
>
>switch
><formcall>
>         normal form call info...
>         xfa.submit = circuit.formprocess
>         xfa.fail = circuit.formcall
>         include = dsp_form
></formcall>
><formprocess>
>         include = act_formprocess
></formprocess>
>
>dsp_form
>cfparam name=Attributes.message deffault=""
>#Attributes.message#
><form>
>         fields (fname, lname, etc...)
>         hidden fuseaction = #fa.submit#
>         hidden fail= #fa.fail#
></form>
>
>act_formprocess
>passed = true
>message = "Please correct the following errors<br>"
>if len(trim(fname)) eq 0
>         passed = fail
>         message = message & "First name<br>"
>end if
>other server side checks
><cftry>
>if not passed
>         <cfthrow message="#message#" type="formerror">
>end if
><cfquery>
></cfquery>
><cfmodule template="#fusebox.siteroot##self#" message="New user 
>successfully added." fuseaction="common.message">
><cfcatch type="formerror">
>         <cfmodule
>                 template="#fusebox.siteroot##self#"
>                 message="#cfcatch.message#"
>                 fuseaction="#Attributes.fail#"
>                 attributeCollection = "#Attributes#">
><cfcatch>
></cftry>
>
>
>
>end
>***********************************************************
>"There are only two ways to live your life.
>One is as though nothing is a miracle.
>The other is as though everything is a miracle. "
>
>- Albert Einstein (1879-1955)
>***********************************************************
>Michael "Maxx" Porter
>Advanced Macromedia ColdFusion 5.0 Certified Developer
>
>mailto:[EMAIL PROTECTED]
>



end
***********************************************************
"There are only two ways to live your life.
One is as though nothing is a miracle.
The other is as though everything is a miracle. "

- Albert Einstein (1879-1955)
***********************************************************
Michael "Maxx" Porter
Advanced Macromedia ColdFusion 5.0 Certified Developer

mailto:[EMAIL PROTECTED]

==^================================================================
This email was sent to: [email protected]

EASY UNSUBSCRIBE click here: http://topica.com/u/?bUrFMa.bV0Kx9
Or send an email to: [EMAIL PROTECTED]

T O P I C A -- Register now to manage your mail!
http://www.topica.com/partner/tag02/register
==^================================================================



Reply via email to