It's not a secret anymore!*
The moose likes Servlets and the fly likes Values are still mainaining in session even i removed from it Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Values are still mainaining in session even i removed from it" Watch "Values are still mainaining in session even i removed from it" New topic
Author

Values are still mainaining in session even i removed from it

rakesh kopperapu
Greenhorn

Joined: Oct 17, 2008
Posts: 8
i am setting attributr in the controller like this
request.setAttribute("xxx",xx)

i am getting this in the jsp page and displaying values

in the top of the controler i am checking
if(request.getAttribute("xxx") != null){
request.removeAttribute("xxx");
}
so values should be removed from the session,but not removing from the session
my task is i am choosing options from select bOx,and click submit means values are coming,

after doing signout and again signin in this situation also values are highlighted in the select box which i selected previously ,did i made any mistake
K.Suresh Kumar
Ranch Hand

Joined: Nov 21, 2007
Posts: 41
Hi,
just use session.invalidate() after sign out.
you session will be destroyed and you will get new session when you are
signin.

Regards,
Suresh Kumar.K
Amit Ghorpade
Bartender

Joined: Jun 06, 2007
Posts: 2716
    
    6

Hi rakesh kopperapu welcome to Javaranch ,
Just make sure that you are not looking at a cached page.


SCJP, SCWCD.
|Asking Good Questions|
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Values are still mainaining in session even i removed from it
 
Similar Threads
JSP Form values Not able to submit
How to populate html:select options in struts
Session attributes
SQL Select to concat rows
Need suggestions and help for my scenario in struts