Subject | RE: [firebird-php] Duplicate numbers |
---|---|
Author | Alan McDonald |
Post date | 2006-05-23T14:47:29Z |
> Milan Babuskov wrote:CHANGE IT TO
>
> > Jochem Maas wrote:
> >
> >>ai, a submit handler - the first thing it does it disable to
> the submit button,
> >>then is submits the form.
> >
> > I found that this doesn't work on some browsers (can't remember
> which one and
> > which version), so I add an additional boolean flag to check:
> >
> > <input type=hidden name=clicked value=0>
> >
> > <input type=submit value=Go onClick="return check();">
> >
> > <script>
> > function check()
> > {
> > if (document.form.clicked.value == 1)
> > {
> > alert('You already clicked. Please wait.');
> > return false;
> > }
> > document.form.clicked.value = 1;
> > return true;
> > }
> > </script>
>
> Except the problem is
>
> <a class="button" accesskey="A" href="ticketaddserve.php?enqno=0">Add
> Ticket</a>
<a class="button" accesskey="A" href="javascript:getticket();">Add
Ticket</a>
then the getticket function can set the href location to
ticketaddserve.php?enqno=0 if the gate is open
Alan
>
> Runs ticketaddserve.php twice every time on a double click :(
>
> --
> Lester Caine - G8HFL