View Full Version : Bookmark Script Question
10-25-2003, 08:33 AM
Is there a script that prevents users from bookmarking a page?
If so, please share it with me.
10-25-2003, 09:10 AM
A script to disable CTRL+D
10-25-2003, 03:30 PM
I KNOW THAT THERE IS A SCRIPT TO DISABLE CTRL BUT I DO NOT KNOW IT.
IF U SERCH FOR IT IN GOOGLE I AM SURE U WILL FIND SOMEHTING.
HOWEVER YOU CANNOT DISABLE CRTL+D
10-26-2003, 04:22 PM
I assume no one knows how to do this
10-26-2003, 04:50 PM
<rant>First of all, some things can be overridden while others can't. Bookmarking can take place in a number of ways, and to prevent it you need to destroy part of the user interface. The browsers don't like this, the users don't like it, and you don't like the consequences it will give to your user base. One of the rules when designing a site targetted at end users is to put no demand on the user agent to support anything at all, to always have fallbacks if a feature doesn't work, and to never change the user interface from what the user is used to and feels comfortable with. This means that you should not try to do something like this. However, even if you can, you must be aware that some things can be "caught and prevented" from the document's perspective while it will still have an effect on the user interface.</rant>
10-27-2003, 02:01 AM
I just need to prevent one page from being bookmarked, I didnt realize it was such a conspiracy
10-27-2003, 03:53 AM
Not a conspiracy, just a break of form. It's one of those things that shouldn't be done, even if many script kiddies like to do it. IF you have a good reason, for example to protect results from a form or something like it, why not try a serverside solution, and tell the user on the page NOT to bookmark it (and what to bookmark instead). Users are generally not willing to break against a request such as that since they fear something will not work next time they need the bookmark or when they may need to use your service. And as for those who would break the rule just because, don't you think they would get around it. I know I have at least four easily used ways around it.
By the way, you should be able to cancel all key presses of c-d using the keypress handlers discussed multiple times on these forums before. Search these forums for onkeypress, keypress event, key(press/up/down) capture, and/or prevent in some combination and see if you can't find anything. I know I have partaken in discussions similar to this one before. I can't guarantee that the user interface event (bookmarking) gets cancelled together with the document keypress event (registering the input), however.
10-27-2003, 05:07 AM
Are you preventing a page from being bookmarked that comes from a POST request? If so, Just check from the server-side code if the request is a GET or POST. If a GET request is detected, you can assume that the page came from a bookmark or the user entered the url directly in the address bar. You can then prevent the page from being displayed by redirecting to another page.
Powered by vBulletin® Version 4.2.2 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.