IN the whole project my role is very small but its not working help me folks my role is registared user logs in when he click on a link , this link redirect to my home page i have in corporated all the bussiness logic which is working fine but when i click on the log out button its not working since i am redirecting, my jsp page, where my home page become a part of the main page,(as object dies when redirected)hence how to make my logout button work. is there any way........... when i asked superiors they suggested me to close the whole window when i click the logout when i included the java script window.close code its also not working i do not know why.............
A redirect, means the first page tells the browser to make a new request to the target page. Request scope objects are no longer available after a redirect because it is a new request. If you need to pass data to the page you are redirecting to, you have to use a query string and pass them as request parameters (or save the data as session or application scope objects).
Joined: Aug 10, 2006
Firstly thanks for getting me a reply, but Divya Guttikonda since i am redirecting i will not be able to close or logout from the main window(from the page where it is redirecting to my page) even i am unable to close the iexplorer window(main window as well as sub window from my home page which is part of the main window).
is there any code such that when logout is clicked that must directly invoke the "X" mark i.e close button which is in the top right corner of the Internet Explorer window.
Why would you want to do that? My understanding of your problem is that you want to logout a user(i.e. invalidate the session) and direct him to a home page. If that's the case, then Lynette Dawson has already mentioned the code that will do this for you.
since i am redirected to a new home page hence i do no have the login object hence there is no question of invalidating login user session i have created a new session in which all my processes are carryed, hence that is the only option with me to directly close the internet explorer window which automatically invalidates all my sessions.