• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to disable CTRL+F

 
Sanjeev Gowda
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all Java Gurus,
I have created a jsp page and i want to disable CTRL+F bcoz when ever any user searches the page through CTRL+F the whole allignment gets changed so i want to disable it or either redirect it and give a alert message that CTRL+F is disabled. Please solce my Query and also tell me where to call the function for disabling or redirecting. As the user can press CTRL+F at any time or any where in the page.
Thanks in Advance
Regards
Sanjeev
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64832
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Firstly, this has nothing to do with JSP so I'm moving it to the HTML forum.

Secondly, what an incredibly unfriendly thing to do! Why not just fix your code?
 
Zip Ped
Ranch Hand
Posts: 336
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You need to capture the keystroke combo and return the javascript function so that the browser action is not taken in the first place.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic