May be you can use AjaxFormSubmitBehavior?


steve222 wrote:
> 
> Hi.  Can anyone recommend a good strategy for handling and dislplaying
> validation error messages when using Ajax? 
> 
> I want my basic field validation error to show next to the relevant input
> text boxes, and have used my own FormComponentFeedbackBorder to do this.  
> 
> I still want a feedback panel for more fatal backend errors - eg, "record
> already exists", "concurrent record modification", etc.  
> 
> Problem.  If I put a feedback panel on the page, and repaint this in my
> button's onError with target.addComponent(feedback) - then I get
> duplicates of my field validation errors in my panel.  Not what I want.  
> 
> If I only repaint the feedback onSubmit then I can catch the backend error
> and display my message. But subsequent Ajax form submissions don't refresh
> the page, so the error message in the feedback panel "sticks" on the page.
> 
> Not sure how to clear out existing errors in the feedback panel when using
> Ajax, so have now used a label on my page instead, and manually clean up
> after myself.  But is this the best way to go?
> 

-- 
View this message in context: 
http://www.nabble.com/Ajax-validation-error-messages-tp19190006p19190919.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