There's no need to save in the context. Just make it a property of the
action bean itself. Then, from profile.jsp, you can refer to the user
object with a JSTL expression like
"${actionBean.user.someUserProperty}".On Tue, Mar 24, 2009 at 7:11 AM, Sneha Manohar <[email protected]> wrote: > Hi All , > I have link on index.jsp <a href="/profile.jsp"> profile.jsp</a> > > My LogInActionBean sets the user & forwords to index.jsp. I wish to pass > user object to profile.jsp ..can you pls help me in this regard. > > public class LoginActionBean extends AnoigmaActionBean { > > this.setUser(user); > return new ForwardResolution("/index_1.jsp"); > } > > This user object is saved in the context > > public class AnoigmaActionBeanContext extends ActionBeanContext { > public User getUser() { > return (User) getRequest().getSession().getAttribute("user"); > } > /** Sets the currently logged in user. */ > public void setUser(User currentUser) { > getRequest().getSession().setAttribute("user", currentUser); > } > > Thanks > Sneha > > ________________________________ > Connect with friends all over the world. Get Yahoo! India Messenger. > ------------------------------------------------------------------------------ > Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are > powering Web 2.0 with engaging, cross-platform capabilities. Quickly and > easily build your RIAs with Flex Builder, the Eclipse(TM)based development > software that enables intelligent coding and step-through debugging. > Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com > _______________________________________________ > Stripes-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/stripes-users > > -- Turtle, turtle, on the ground, Pink and shiny, turn around. ------------------------------------------------------------------------------ Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are powering Web 2.0 with engaging, cross-platform capabilities. Quickly and easily build your RIAs with Flex Builder, the Eclipse(TM)based development software that enables intelligent coding and step-through debugging. Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com _______________________________________________ Stripes-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/stripes-users
