java - Display validation messages in struts 2 -
i have form in application in want validate user inputs. has combo box populated db table. have go action class first populate it(for eg: populateformaction). go form.jsp page.
but problem @ time of validation. have set populateformaction input result follows
<result name="input" type="redirect">/populateformaction</result> but when returned form.jsp, doesn't show validation errors. think because of use of populateformaction in between action handler , form.jsp.
there 2 solutions problem
call method populating combo, efore returning input (if there validation error). , dont use type redirect, instead directly move form.jsp. of course, possible if have populate combo , validate methods in same action class.
pass action errors parameters populateformaction follows.take here
i m not sure whether there 's' after actionerror or not, try both
Comments
Post a Comment