Inside your onSubmit method do this

if(!submitted)
{
//normal submit code

submitted = true;
}

and have boolean submitted = false; in your class

that way no matter how many times someone clicks submit the submit code
should only run once

Thats one way anyway




hillj2 wrote:
> 
> That would require me to either implement markup inheritance or to place
> the hidden field in the markup of all my extended forms, wouldn't it?  I
> was hoping to make all my form instances as ignorant of the base class as
> possible, but I guess if I have to implement one of these solutions, it's
> better than having it not work at all.
> 
> I assume the "input" variable is the value of the hidden field?
> 
> Also, if the validation fails, can I still send the user to a custom error
> page instead of just putting an error message in the feedback panel? 
> Sorry, I haven't dealt much with validators.  I usually just validate form
> data manually in onSubmit.
> 
> I'll start working with this solution and see what I can come up with. 
> OnUnload isn't working our for me so far.  Partly because I can't attach
> the event to the page with the way my code is currently set up.
> 
> Thanks for the suggestion.
> 
> Joel
> 

-- 
View this message in context: 
http://www.nabble.com/Double-submit-problem-tp15957979p15976516.html
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to