for stuts 1, to get session, via the following
session=request.getSession();
session.setAttribute(PERSON, person); /* person is object name */
for struts 2, to get session, via the following
Map session=ActionContext.getContext().getSession();
session.put(PERSON,
Personally, I'd use SessionAware and reduce coupling even further.
The docs for both methods should answer this question fairly completely.
The session is exposed as a map in S2, and as a servlet spec artifact in S1.
Dave
On Wed, May 8, 2013 at 12:15 PM, john lee sh_thorn_b...@yahoo.com
how do i get a handle to Session / Request from an action implementing
import com.opensymphony.xwork2.Preparable;?
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Hi,
http://struts.apache.org/2.x/docs/how-do-we-get-access-to-the-session.html
http://struts.apache.org/2.x/docs/how-can-we-access-the-httpservletresponse.html
Thanks,
Nuwan
On 8/17/07, Eugen Stoianovici [EMAIL PROTECTED] wrote:
how do i get a handle to Session / Request from an action
Eugen Stoianovici wrote:
how do i get a handle to Session / Request from an action implementing
import com.opensymphony.xwork2.Preparable;?
http://struts.apache.org/2.x/docs/how-do-we-get-access-to-the-session.html
http://struts.apache.org/2.x/docs/how-can-we-access-the-httpservletrequest.html
Laurie Harper wrote:
Eugen Stoianovici wrote:
how do i get a handle to Session / Request from an action
implementing import com.opensymphony.xwork2.Preparable;?
http://struts.apache.org/2.x/docs/how-do-we-get-access-to-the-session.html
On 9/28/05, Wendy Smoak [EMAIL PROTECTED] wrote:
From: Troy Bull [EMAIL PROTECTED]
snip/
c:out value=${session.variable}/
%= session.getAttribute(variable) %
So the c:out tag isn't working, any ideas why that would be?
Try just:
c:out value=${variable}/
It will check page,
Hello,
We're looking at unifying three existing standalone struts applications
into one core struts application with two modules. We'd like the modules
to remain as autonomous as possible so that we could replace or make one
of them stand on it's own again in the future.
My question is how to
8 matches
Mail list logo