• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

Back Button & Mouse Risk click

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hii,
can anyone pls. tell me, (a) how to disable IE Browser Back button using JavaScript. (b) how to disable the Mouse right click button in the above said page.
With Thnks and Rgds,
SSV.
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
WHY! Do you want to do this??
 
sakthi shan
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I want to incorporate this in my Application...
 
Eric Pascarello
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I figured that out, but what purpose is this serving?
You can not disable the back button.
If you want a useless script then sarch google for "No Right Click JavaScript" and you will find 100's of them.
People hate when you mess with their browsers, you can not hide code/pictures/text/etc since it exsists in your cache. Are you also going to disable (ALT <-) combo too?
If you are doing both of these to keep a user from going back to the previous page there is a better solution. Plus a person can disable JavaScript and get around all your little things.
Eric
 
sakthi shan
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
can you pls. tell me that best solution???
cheers,
SSV.
 
Eric Pascarello
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
best solution would be server side
instead of a link you can use
document.location.replace("theUrl");
It replaces the current page in the history so you can not go back to it.
Another bad solution that I am known for on the net is this link:
http://www10.brinkster.com/A1ien51/basics/backbutton.htm
Eric
 
sakthi shan
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
can you pls. tell me the solution for back button - disabling alone???
With Thanks,
SSV.
 
Eric Pascarello
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can not just disable he back button. You have to do either of the things I said above. The replace method or the link...
 
Yeah, but does being a ninja come with a dental plan? And what about this tiny ad?
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic