Re: Avoiding duplicate orders?
| From: | Sophie Mattoug | Date: | Thu, 20 Nov 2003 16:46:21 +0000 |
| Subject: | Re: Avoiding duplicate orders? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-170436@lists.php.net to get a copy of this message | ||
The way I do is, on the result page, to create a variable (for example $done) and I put to into the session. So if this variable already exists, I don't re-execute the form treatment code.
Hope this helps
--
Cordialement,
---------------------------
Sophie Mattoug
Développement web dynamique
sophie@mattoug.net
---------------------------
J J wrote:
>What is the simplest way to avoid duplicate order
>entry on a form? Some people aren't patient enough to
>wait for the SSL/credit card processing and will click
>the submit button two, three, or more times causing
>duplicate orders.
>
>Is there a quick way to disable the submit button at
>least in javascript? Better yet, something quick and
>easy that could be done server-side without a lot of
>programming like cookies, database flags, etc?
>
>I've thought of a few things (like hidden variables
>with an order ID or cookies/flags) but this really
>should be a quick fix since it's not a big problem on
>the site.
>
>Thanks in advance for any tips or techniques!
>
>__________________________________
>Do you Yahoo!?
>Free Pop-Up Blocker - Get it now
>http://companion.yahoo.com/
>