If I'm understanding you correctly and you're looking for a struts config
type solution then you really need to set a forward on your form processing
action to send you back to page A. Something like this in struts-config.xml

<action path="/myFormProcessorActionForPageB"
                type="myPackage.MyFormProcessorAction"
                name="formForPageB"
                scope="request"
                validate="true"
                input="/WEB-INF/pages/pageB.jsp">
                <forward name="success" path="/WEB-INF/pages/pageA.jsp"/>
</action>

Then in your execute() method in MyFormProcessorAction code to fill in the
gaps:

// process the form
        ...
// send the user back to pageA
        return (mapping.findForward("success"));

Obviously any other page which can invoke pageB would have similar <forward>
set up.

Hope this helps,
Matt.

-----Original Message-----
From: Adrian Theuma [mailto:[EMAIL PROTECTED]]
Sent: 11 March 2002 15:22
To: Struts Users Mailing List
Subject: Problem


Hi,

please look at the following problem scenario.

Assume that you are on page A, and there is a link on page A to page B.
Page B is a form. I would like that when a user clicks on the submit
button on page B, the user is returned to page A. Keep in mind that page
B can be accessed from pages other than A. i.e. page B must basically
return control to the page from which it was called.

I will greatly appreciate a clean way to do this.

Thanks.

Adrian.

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


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

Reply via email to