how to disable Back Button in Internet Browser
-
Hi all, Do anybody have the code for disabling the back button in Internet Browsers. I have tried this code but this isnt working : window.history.forward(1); I even placed in the head section but it is not working. can u please help me since it is very urgent to me Regards, murali
-
Hi all, Do anybody have the code for disabling the back button in Internet Browsers. I have tried this code but this isnt working : window.history.forward(1); I even placed in the head section but it is not working. can u please help me since it is very urgent to me Regards, murali
ballameharmurali wrote:
window.history.forward(1);
This code does not disable the back button, it is just navigation hack which could fail with browser version and also disabling javascript. You cannot/shouldn't disable the back button. Rather than relying on the browser you should design your system(presuming there is a server side) to detect/prevent the user's activity.
-
Hi all, Do anybody have the code for disabling the back button in Internet Browsers. I have tried this code but this isnt working : window.history.forward(1); I even placed in the head section but it is not working. can u please help me since it is very urgent to me Regards, murali
HI, please ensure following to get the desired result. (I AM ASSUMING YOU ARE USING ASP.NET 2.0 AND C#) Simply use the page directive OutputCache Location = "none". This should help. If not do let me know, the behavior faced.
PLEASE DO NOT FORGET TO MARK AS ANSWER IF FOUND USEFUL/RELEVANT, SO THAT OTHERS CAN FIND IT EASILY. Software Developer, Pune, India