What is the message you're receiving? From what you've provided I can't tell if it's that it can't find the redirect result type, or the /homeSecure.action to redirect to. (*Chris*)
On Mon, Sep 22, 2008 at 4:03 PM, Gianluca Musella < [EMAIL PROTECTED]> wrote: > Hello Chris. Thank you. > > > Are you saying you want to set the default result type to "redirect" > > globally or that you just want a global result type of "redirect" to be > > available to your actions? > > The second. I wrote this: > > <package name="almayer" namespace="/" extends="struts-default"> > > <global-results> > <result name="login">/component/login.jsp</result> > <result type="redirect" > name="homeSecure">/homeSecure.action</result> > <result type="redirect" > name="homeUnsecure">/homeUnsecure.action</result> > </global-results> > > Te problem is that the struts.xml is validated in the startup phase, > but if some action returns "homeSecure", I receive an error because > the forward isn't defined. > > That's all. Where is my fault? > > Gianluca > > > > > > 2008/9/22 Chris Pratt <[EMAIL PROTECTED]>: > > Are you saying you want to set the default result type to "redirect" > > globally or that you just want a global result type of "redirect" to be > > available to your actions? > > > > If the former, just redefine the "redirect" result type in your package > and > > set it to default="true", like: > > > > <result-types> > > <result-type name="redirect" > > class="org.apache.struts2.dispatcher.ServletRedirectResult" > default="true"/> > > </result-types> > > > > If the latter, make sure your package extends "struts-default" that's > where > > all the standard result types get defined. > > (*Chris*) > > > > > > On Mon, Sep 22, 2008 at 9:25 AM, [EMAIL PROTECTED] < > > [EMAIL PROTECTED]> wrote: > > > >> > >> Ho all. > >> > >> I'm il train! > >> > >> It is possible in struts.xml to have global result of type redirect? > >> > >> My struts.xml doesn't give validation errors, but results or type > redirect > >> aren't visible ho the controller. > >> > >> Please help > >> > >> Gianluca > >> > >> > >> > >> Inviato da iPhone > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >