I’m trying to call using action forward property in struts 1 from struts-config, and I would like to invoke another action, which it’s located in another struts.config file. And obviously it doesn’t work!
My code is:
In "struts-misExpedientes.xml"
<action path="/s99bIrInicio" forward="$$$WEBROOT_ENVIRONMENT$$$/comunJSP/s99binicio.do">
the other xml file is "struts-comun.xml"
<action path="/s99binicio" forward="/s99bIrWelcomeMensajeDia.do" />
Notes:
"WEBROOT_ENVIRONMENT" is a variable I have declared in a property file and its value is [http:// localhost:8100/s99bEnvironmentWar]
I thank any idea you could provided.
If you mean that you want to forward from one webapp to another webapp, then this is not possible. Every webapp is isolated from the other webapps. Each has its awn classes, libraries and sessions, different from the other one. So passing HttpRequest objects from one to the other doesn’t make sense.
You should probably redirect to the other webapp. BTW, action chaining is discouraged by Struts, even when it’s possible, inside a single wepapp.
EDIT: it appears that you’re using modules. So do what the documentation says: