Forum Moderators: open
ther is the location.replace("new") property to replace the current page
from history.
but the prob is i'm making a logout page...So after logging out..i
shouldn't c the previous page instead i should see another page showing ur
logged out..
so is there any way thr which i can replace the history urls,.
Just typing that gave me an idea -- maybe you can respond to a Log-IN by opening the site in a new window opened by javascript. Then you can respond to a log-OUT by closing that window (since your script opened it) and voila, the Back Button will not allow anyone to get into a record of the session that just finished.
what i'm doing is something like this...in login page
session.setAttribute("username",user)
nd in logout page
session.setAttribute("username",null)
and in all other pages
if (session.getAttribute("username")!= null)
.by that we can go to back page..but no processing can be done...then iit guides to new page..
but i dono other way..can u help out.
and no..i don't want to use no-cache in meta tag
Anyway i figured it out....
thanks for all those whoi tried to help me out.
what i did was .... in the logout page...in javascrcipt i added an extra word to the cookie. of the current document.
something like this
document.cookie="someword"
then in all other pages in the head tag i included
if((document.cookie!= "")&&(document.cookie.indexOf("someword")!=-1 ))
window.open("id of the page u want o direct to", "_top");
now it works fine...even if i click the back button..it doesn't shows the previous pages...it brings back to the page i put in the open option.