[email protected]
[Top] [All Lists]

Re: Retrieve a session attribute

Subject: Re: Retrieve a session attribute
From: Rahul P Akolkar
Date: Thu, 14 Apr 2005 14:57:20 -0400
> I thought a JSP would share the same session within
> the servlet if a session already exists in the
> container. JSP is eventually translated into servlet
> code, doesn't it? 
> I insert the log message code in the servlet before
> getting to the JSP and find that a session already
> exists at the point. If a session in JSP is unrelated
> with a session in servlet, how these two share session
> attributes?

Again, the page directive specifies whether the JSP joins a session (if 
one is already associated with the current request -- as in your case). By 
specifying the attribute value "false", you're saying you do not want to 
join the session, and hence, waiving your ability to access anything 
within the session.

Please read the related bit here:


<Prev in Thread] Current Thread [Next in Thread>