File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes Back button disable not working Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Back button disable not working" Watch "Back button disable not working" New topic

Back button disable not working

sridhar lakka
Ranch Hand

Joined: Jan 02, 2007
Posts: 109
Hi All,
Thanks in advance.
I want to disable the back button in my browsers we are using IE only.
I have written following code onload of page, window.history.forward(1);.
And for some pages ,the pages which are just display and the page which doesnt have any function to be called onload of that page is working fine.
But i have some pages where user can enter some values and on that page load iam calling some functions.
In that case this is not working.

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63844

Please read this.

What are you trying to accomplish by disabling back? It really is a rather unfriendly thing to do.
[ May 07, 2007: Message edited by: Bear Bibeault ]

[Asking smart questions] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: Back button disable not working
It's not a secret anymore!