Re: Prevent Submit Button Clicked Twice/ Prevent Double Click
Chuck Hill <[email protected]> Wed, 15 Apr 2009 09:45:11 -0700
| Newsgroups | gmane.comp.web.webobjects.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi Federico, On Apr 15, 2009, at 9:32 AM, Federico Cattozzi wrote: > Hi, > i'm italian developer and i'm new member of this mailing list. Welcome! > I have a problem with WO: in a my application there is a booking > wizard composed by a sequence of components, from a component to the > next i send some data with a form with attribute "multipleSubmit = > true;" (because the are two WOSubmitButton, one to undo and one to > continue), good, how can i prevent a submit button to click twice? > Setting WOAllowsConcurrentRequestHandling=false property seems > doesn't help me. No, that is for something different. You probably want that set to true. > Using Javascript like this onclick = "this.disabled=true; > this.submit();" to disable the button while the component is > calculating, blocks the submitting. The best solution is probably to make your application able to handle double clicking. One way to do this is to set a flag when the first click is detected and then just return the next page (or the current page) if a second click happens. JavaScript like this might work: onclick = "this.submit(); this.disabled=true;" Chuck > > Please, help me. > Thank you. > > -- > Federico Cattozzi > _______________________________________________ > WebObjects-dev mailing list > [email protected] > http://www.omnigroup.com/mailman/listinfo/webobjects-dev -- Chuck Hill Senior Consultant / VP Development Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems. http://www.global-village.net/products/practical_webobjects