Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > de.comp.lang.javascript > #4853

Re: Doppelte Eingabe

From Ralph Stahl <post@rstahl.de>
Newsgroups de.comp.lang.javascript
Subject Re: Doppelte Eingabe
Date 2017-02-03 10:27 +0100
Organization albasani.net
Message-ID <o71ie1$963$1@news.albasani.net> (permalink)
References <o6uvk2$qva$1@news.albasani.net> <1t58931f77i3f82n3e8%sfroehli@Froehlich.Priv.at> <o6vg9b$e26$1@news.albasani.net> <1t58935c1bi1e45n3e8%sfroehli@Froehlich.Priv.at> <aa7ec64e-3970-59ca-f8e9-647206e26680@arcor.de>

Show all headers | View raw


Christoph M. Becker schrieb:
> On 02.02.2017 at 17:24, Stefan Froehlich wrote:
> 
>> Im wesentlichen läuft es darauf hinaus:
>>
>> | <script language="JavaScript">
> 
> Das language Attribut sollte eigentlich schon lange nicht mehr verwendet
> werden. Aber dazu kann ein anderer sicher mehr sagen. :)
> 
>> | 	var isSubmitted;
>> | 
>> | 	function singleFormSubmission() {
>> | 		if (isSubmitted) return false;
>> | 		isSubmitted = true;
>> | 		return true;
>> | 	}       
>> | </script>
>> | 
>> | <form [...] onsubmit="return singleFormSubmission();">
> 
> Die Funktion ist nicht mal nötig. Es geht auch:
> 
>   <form […] onsubmit="return !!isSubmitted++">

2x Ausrufezeichen, also !!isSubmitted++ ?

Back to de.comp.lang.javascript | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Re: Doppelte Eingabe "Christoph M. Becker" <cmbecker69@arcor.de> - 2017-02-02 18:05 +0100
  Re: Doppelte Eingabe Stefan+Usenet@Froehlich.Priv.at (Stefan Froehlich) - 2017-02-02 17:07 +0000
  Re: Doppelte Eingabe Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-02-02 21:02 +0100
    Re: Doppelte Eingabe "Christoph M. Becker" <cmbecker69@arcor.de> - 2017-02-03 00:52 +0100
  Re: Doppelte Eingabe Ralph Stahl <post@rstahl.de> - 2017-02-03 10:27 +0100
    Re: Doppelte Eingabe "Christoph M. Becker" <cmbecker69@arcor.de> - 2017-02-03 11:38 +0100

csiph-web