This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

disable back button  RSS feed

 
shivaram bupathi
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how can i disable back button of the browser from my jsp page

i tried using the following code

//Code to disable the Back Button in Internet Explorer
var URL;
var i ;
var QryStrValue;
URL=window.location.href ;
i=URL.indexOf("?");
QryStrValue=URL.substring(i+1);
if (QryStrValue!='X')
{
window.location=URL + "?X";
}

but sometimes it is not working ,
do i need to do any settings/changes in browser?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!