struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Girish Naik <girish.n...@gmail.com>
Subject Re: response.sendRedirect() with Struts2 within a portlet
Date Sun, 31 May 2009 17:11:40 GMT
There is no documentation as such, but i read it in the book 'Struts 2
Design and Programming: A Tutorial' by Budi Kurniawan.

This result is added to the action mapping in struts.xml file -
e.g.:

        *<action name="login"
            class="com.something.webapp.action.LoginAction" method="login">
            <result name="success" type="redirect">home.action</result>
            <result name="sign_in" type="tiles">
                tiles:showLoginPage
            </result>
            <result name="home" type="redirect">home.action</result>
           <result name="failure" type="redirect-action">
                <param name="namespace">/</param>
                <param name="actionName">home</param>
            </result>
        </action>*


Regards,
---------------------------------------------------------
Girish Naik
Mobile:-+91-09740091638
girish.naik@gmail.com
Helen Rowland<http://www.brainyquote.com/quotes/authors/h/helen_rowland.html>
- "One man's folly is another man's wife."

On Sun, May 31, 2009 at 9:50 PM, Martin Gainty <mgainty@hotmail.com> wrote:

>
> Girish-
>
> can you provide the documentation which suggests Result and Result with
> params for redirect and redirect-action types?
>
> Thanks!
> Martin Gainty
>
> I would never join a club which would have me as a member -  Groucho Marx
> ______________________________________________
> Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité
>
> Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene
> Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte
> Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht
> dient lediglich dem Austausch von Informationen und entfaltet keine
> rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von
> E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
> Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le
> destinataire prévu, nous te demandons avec bonté que pour satisfaire
> informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie
> de ceci est interdite. Ce message sert à l'information seulement et n'aura
> pas n'importe quel effet légalement obligatoire. Étant donné que les email
> peuvent facilement être sujets à la manipulation, nous ne pouvons accepter
> aucune responsabilité pour le contenu fourni.
>
>
>
>
> > Date: Sun, 31 May 2009 13:56:24 +0530
> > Subject: Re: response.sendRedirect() with Struts2 within a portlet
> > From: girish.naik@gmail.com
> > To: user@struts.apache.org
> >
> > I have used redirect in struts.xml file in two ways as :
> >
> > 1.
> >
> > <result name="home" type="redirect">home.action</result>
> >
> > 2.
> >
> > <result name="failure" type="redirect-action">
> >                 <param name="namespace">/</param>
> >                 <param name="actionName">home</param>
> >             </result>
> >
> >
> > Regards,
> > ---------------------------------------------------------
> > Girish Naik
> > Mobile:-+91-09740091638
> > girish.naik@gmail.com
> > Groucho Marx <
> http://www.brainyquote.com/quotes/authors/g/groucho_marx.html>
> > - "A hospital bed is a parked taxi with the meter running."
> >
> > On Sun, May 31, 2009 at 1:50 PM, Crishantha Nanayakkara <
> > c.nanayakkara@gmail.com> wrote:
> >
> > >
> > > Hi,
> > >
> > > I have a requirement to use a response.sendRedirect() within my Action
> > > class. Basically this action class is used to manipulate a porltet.
> > >
> > > Unlike Struts1, we do not directly have any processAction() method and
> > > ActionRequest and ActionResponse objects to do a response.sendRedirect.
> > >
> > > I just want to know how do we get about executing the
> response.sendRedirect
> > > with Struts2? What should be the interface to implement within the
> action
> > > class to do this. (Just like ServletRequestAware to get the
> > > HttpServletRequest)
> > >
> > > Appriciate your help on this.
> > >
> > > Best Regards
> > > Crishantha
> > > --
> > > View this message in context:
> > >
> http://www.nabble.com/response.sendRedirect%28%29-with-Struts2-within-a-portlet-tp23800916p23800916.html
> > > Sent from the Struts - User mailing list archive at Nabble.com.
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> > > For additional commands, e-mail: user-help@struts.apache.org
> > >
> > >
>
> _________________________________________________________________
> Windows Live™: Keep your life in sync.
> http://windowslive.com/explore?ocid=TXT_TAGLM_BR_life_in_synch_052009

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message