You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Milson Fredy Cardona Echeverri <mi...@hotmail.com> on 2004/11/11 18:26:00 UTC

session variable in struts

hi friends

i want to declare a session variable in an action class.

I could to solve it in a servlet class :
HttpSession session = request.getSession();
session.setAttribute("variable name","value");

but in struts ¿how do i do it?

thanks in advance

_________________________________________________________________
Charla con tus amigos en línea mediante MSN Messenger: 
http://messenger.latam.msn.com/


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: session variable in struts

Posted by Daniel Perry <d....@netcase.co.uk>.
Its the same in struts as in servlets!

The execute method of Action is passes an HttpServletRequest.

Daniel.


> -----Original Message-----
> From: Milson Fredy Cardona Echeverri [mailto:milsoncardona@hotmail.com]
> Sent: 11 November 2004 17:26
> To: user@struts.apache.org
> Subject: session variable in struts
>
>
> hi friends
>
> i want to declare a session variable in an action class.
>
> I could to solve it in a servlet class :
> HttpSession session = request.getSession();
> session.setAttribute("variable name","value");
>
> but in struts ¿how do i do it?
>
> thanks in advance
>
> _________________________________________________________________
> Charla con tus amigos en línea mediante MSN Messenger:
> http://messenger.latam.msn.com/
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org