File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes back session management Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "back session management" Watch "back session management" New topic
Author

back session management

baxhuli pema
Greenhorn

Joined: Nov 09, 2012
Posts: 11
Hello, this is my first topic in this forum and I hope to get the right answers here.
I have created a login/logout form and some servlets that will be accessed if the login is successful.
I want to make sure that once the user accesses the first servlet, he will not be able to get back to get back to the
first form by going back through the back button in the browser. I used this:
<script type="text/javascript">
function disableBackButton() {
window.history.forward();
}
setTimeout("disableBackButton()", 0);
</script>
but it doesn't work in firefox. However this is just to disable the button. I need someway that when the back button will be clicked
nothing will happen or at maximum the existing opened servlet will just be refreshed.
I want to know how can I do this with session tracking if anyone has an idea.
Please help me as I am new to servlets.
Thank you.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: back session management
 
Similar Threads
Preventing users from seeing old data using their browser back button
h:commandButton immediate='true'
user session questions
JSP login/logout session problem
Submitting forms with URL re-writing