A tactic I've been planning to use, but don't know if it actually works or
not, is to disable the button first thing in its onClick so the second click
occurs on a disabled button. Does anybody know if this actually works or
not?
- Theo
-----Original Message-----
From: John Huggins [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 28, 2001 3:04 PM
To: Manuel Lemos; [EMAIL PROTECTED]
Subject: RE: [PHP] Double Click
If you are lucky and are feeding this form data to a database, you can
create a unique hash field from other fields that would not change from
click 1 to click 2. Then just make the database treat the hash as a unique
index and it should prevent double entries. Works for me.
Other advice is to not tell the double clicker that had an error; Just
silently ignore their second request.
> -----Original Message-----
> From: Manuel Lemos [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, February 28, 2001 2:55 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] Double Click
>
>
> Hello Fabian,
>
> On 28-Feb-01 03:01:02, you wrote:
>
>
> >Hi,
>
> >I have a page, and when I have to add a product I use a form,
> many people are
> >used to make double click in every task, so when the product is
> sent with a
> >double click in the send button, the program send it twice to
> the data base.
>
> >What can I do to prevent this?
>
> You may want to try this forms generation class that lets you define a
> warning message that shows when the user attempts to submit a form more
> than once.
>
> http://phpclasses.UpperDesign.com/browse.html/package/1
>
> Regards,
> Manuel Lemos
>
> Web Programming Components using PHP Classes.
> Look at: http://phpclasses.UpperDesign.com/?[EMAIL PROTECTED]
> --
> E-mail: [EMAIL PROTECTED]
> URL: http://www.mlemos.e-na.net/
> PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp
> --
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]