Here's a cute way to disable a submit button after it's been pressed:

----- start of code -----------------------
<script language="JavaScript">
 function doSubmit(btn) {
  if (btn.value != "Please wait...")
      btn.form.submit();
  btn.value = "Please wait...";
  }
</script>

<input type=submit name=btnSubmit
    value="Save My Stuff"
  onClick="doSubmit(this)">
----- end of code -----------------------

It depends on client JavaScript, so it's not a total solution.  You'd
still want to do some sort of duplicate transaction checking.  Still,
it's an elegant technique that keeps the user informed.

Keith Meade
www.kmweb.com

----- Original Message -----
From: "HappyToad.com" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Friday, September 29, 2000 11:08 AM
Subject: Refresh Question?


: How can I stop multiple records being added to the database when a user
: clicks refresh on a form action page?
:
: Rich
:
: -----------------------------------------------------------------------
-------
: Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
: To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk
or send a message to [EMAIL PROTECTED] with 'unsubscribe'
in the body.

------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to