Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #25860
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!news-1.dfn.de!news.dfn.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail |
|---|---|
| From | "Mel Smith" <syntel@cox.net> |
| Newsgroups | comp.lang.javascript |
| Subject | Stopping Multi-submits ? |
| Date | Tue, 23 Sep 2014 08:58:41 -0600 |
| Lines | 41 |
| Message-ID | <c8dg58F7c6lU1@mid.individual.net> (permalink) |
| X-Trace | individual.net Y8ZK5yA2QSdUHzdLqizsZwWz8rCS6oEzcKefdP8yNAz7lK7Lhk |
| Cancel-Lock | sha1:I7qGzUJVzv1cCN5KmMq/no+92RY= |
| X-Priority | 3 |
| X-MSMail-Priority | Normal |
| X-Newsreader | Microsoft Outlook Express 6.00.2900.5931 |
| X-MimeOLE | Produced By Microsoft MimeOLE V6.00.2900.6157 |
| X-RFC2646 | Format=Flowed; Original |
| Xref | csiph.com comp.lang.javascript:25860 |
Show key headers only | View raw
Hi:
Situation:
To forestall a user multi-clicking on a submit button, I use JS code
similar to the following:
getobj("mybuttonid").disabled=true ;
getobj("myloginid").submit() ;
(where the getobj() function is simply my short way of using
document.getElementById() )
Result:
If my server response is very slow, my user hitting the submit button
repeatedly will *not* result in successive submits because the submit button
is now disabled.
Problem:
In IE11 (at least), after the new page arrives, if the user decides to
use the 'back arrow' to re-load the previous page, then that submit button
is *still* disabled, when I wish it to be enabled and ready for another
submit
Question:
How do I restrain multiple submits, *but* allow submits again after a
new page has arrived, and then the user 'arrows' back to the previous page
(or pages).
(btw, I tried putting the re-enabling code in the onload event, but I
guess that the onload code doesn't get activated if the user simply uses his
back-arrow to get his previous page ?? )
Thanks.
-Mel Smith
Back to comp.lang.javascript | Previous | Next — Next in thread | Find similar | Unroll thread
Stopping Multi-submits ? "Mel Smith" <syntel@cox.net> - 2014-09-23 08:58 -0600
Re: Stopping Multi-submits ? Cezary Tomczyk <cezary.tomczyk@gmail.com> - 2014-09-23 20:22 +0200
Re: Stopping Multi-submits ? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2014-09-24 02:50 +0200
Re: Stopping Multi-submits ? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2014-09-23 20:31 +0200
Re: Stopping Multi-submits ? "Mel Smith" <syntel@cox.net> - 2014-09-23 16:27 -0600
Re: Stopping Multi-submits ? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2014-09-24 00:54 +0200
Re: Stopping Multi-submits ? "Mel Smith" <syntel@cox.net> - 2014-09-24 08:24 -0600
csiph-web