The most common way I've seen is by disabling the submit button.  If your
audience uses strictly IE, then you can use JavaScript to actually disable
the button making it so that the button can no longer be pressed.  If you
have a mixed set of users, you can change the submit button to a "button"
button and use JavaScript to submit the form as in:

        <SCRIPT LANGUAGE="JavaScript">
        <!--
                var formSubmittedInd = 0;

                function submitForm() {
                        if (formSubmittedInd == 0) {
                                formSubmittedInd = 1;
                                document.myForm.submit();
                        } else {
                                alert("Patience is a virtue.");
                        }
                }
        // -->
        </SCRIPT>


        <INPUT TYPE="Button" VALUE="Submit" onClick="submitForm();">

Also, make sure that your confirmation screen is different from the actual
action page as in:

        form.cfm (submits to) action.cfm (forwards to) success.cfm

This way, when the user is looking at the success/confirmation message, if
they hit refresh, the action.cfm page is not executed again.

HTH

--
Mosh Teitelbaum
evoch, LLC
Tel: (301) 942-5378
Fax: (301) 933-3651
Email: [EMAIL PROTECTED]
WWW: http://www.evoch.com/


> -----Original Message-----
> From: Paolo Cesana [mailto:[EMAIL PROTECTED]
> Sent: Thursday, February 27, 2003 11:15 AM
> To: CF-Talk
> Subject: Form expiration
>
>
> Hi,
> how would I go about expiring a form submission so that users
> cannot click on refresh and submit the form again?
>
> Tks/Rgds
>
>
>
> Paolo Cesana
> IT Development Mgr.
> "Electricity is not the result of a series of upgrades to the candle"
> Auth. unknown
>
>
> Miami International Forwarders (MIF)
>
> Phone: (305)594-0038 Ext. 7326
> Fax: (305)593-0431
> <mailto:[EMAIL PROTECTED]>
> <http://www.mif.com/>
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to