Re: form submit limit

by "Cyanide _7" <leo7278(at)hotmail.com>

 Date:  Tue, 18 Apr 2000 04:46:19 CDT
 To:  DNicholson(at)APACMail.com
 Cc:  hwg-languages(at)hwg.org
  todo: View Thread, Original
can't recall if you ever got a response, but this idea just came to me. 
forgive any typos or bugs, im writing this off the top of my head.

first of all, use a standard button rather than a submit. then have its 
onClick event handler invoke the form submition. immediatly afterward, null 
out the event handler all together and it kills the button:

<input type="button" value="submit"
  onClick="this.form.submit();this.onclick = null;">

try that. the submit function should work just fine because your submitting 
to a perl script rather than using the mailto: action (then it gets tricky). 
the only problem is if they wish to hit STOP because they made a mistake, 
they have to reload to reactivate the button. good luck - Cyanide_7

>
>Hello all,
>
>I am trying to figure out a way to limit how many times a forms submit
>button can be hit.
>
>I am submitting the form data to a perl script and seek only to prevent the
>data from being e-mailed more than once by the script.  I don't want the
>user to even notice.  If they hit the submit button a second time I just
>want it to do nothing.  Get or post method, I need a solution for both.
>
>Is there a SIMPLE way to do this in HTML alone or if not, a perl or even
>javascript solution?
>
>TIA.
>
>Dale Nicholson

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com

HWG: hwg-languages mailing list archives, maintained by Webmasters @ IWA