Forward to different JSPs 2007-08-15 - By Laurie Harper
Back Jasper Floor wrote: > On 8/15/07, JasDA@(protected) <JasDA@(protected)> wrote: >> Hi, >> >> <action >> path="/secure/dataChecks" >> name="emptyForm" >> type="org.springframework.web.struts.DelegatingActionProxy" >> input="/secure/dataChecks.jsp" /> >> >> So here it is only possible to return to the given input JSP "dataChecks.jsp ". How can I return to the calling JSP without defining one action tag for every single JSP? > > If you don't close your actionmapping right away you can put <forward> > tags in which you can define diffrent places to go. > > <action ...> > <forward.../> > </action> > > In your action class you can look for request params to decde which way to go. > > http://struts.apache.org/1.3.8/userGuide/building_controller.html#config > > for more info.
Also note that you don't need to define 'input' for every action. It is only used if the action is accepting and validating a form submit, and the validation fails. So, you will need a separate action mapping for form submission you want to handle with a different input page but should be able to remove input from your other action mappings.
L.
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ To unsubscribe, e-mail: user-unsubscribe@(protected) For additional commands, e-mail: user-help@(protected)
|
|