The application.xml file of the EAR has two different wars with different context roots specified for them? What else should I update to imply to the server that the context root has changed? I tried by adding a global forward:
<forward name="test2" contextRelative="true" path="/test2/forwardToTrainingDB.do" redirect="true"/> and put the url as test2. But , when I run the appl, the complete url formed is: http://localhost:9080/test1/test2 whereas I want it to be http://localhost:9080/test2/forwardToTrainingDB.do What should i do? On 8/13/07, Paul Benedict <[EMAIL PROTECTED]> wrote: > > SwitchAction does not switch between applications. It switches between > Struts modules within one application. What you want to do is include the > context root in your paths. There's an attribute for that. I believe it's > contextRelative=true > > Paul > > On 8/13/07, ANIMESH SAXENA <[EMAIL PROTECTED]> wrote: > > > > Could you please mention which struts version?? > > > > On 8/13/07, Pooja Kaur <[EMAIL PROTECTED]> wrote: > > > > > > Hi, > > > I have 2 war files added to an EAR. Both of them have a different > > context > > > root. Eg. Module A has test1 as the context root and Module B has > test2 > > > I did the following in the struts-config of Module A which is the > > default > > > module: > > > 1. Added an action > > > > > > <action path="/toModule" type="org.apache.struts.actions.SwitchAction > "/> > > > > > > 2. The link to switch the module has the URL eg. > > > > > > toModule.do?prefix=/test2 > > > &page=/forwardToTrainingDB.do > > > > > > When I click on the link with the above url , i get 400 (Bad Request) > > > Error > > > message. > > > > > > The mapping for forwardToTrainingDB.do is present in the struts-config > > xml > > > file of test2 module. > > > > > > Please help me how to resolve this problem. > > > > > > Thanks > > > > > > > > > > > -- > > Animesh Saxena > > > > > > http://inlovewithlinux.blogspot.com > > >