View Full Version : need help with script
GringoBob
12-14-2013, 03:25 PM
looking for a script that will override browser instruction "do not follow" that we can embed in our html pages
HELP !!!!
jscheuer1
12-14-2013, 03:29 PM
That instruction is not for and does not affect browsers, it's for bots and cannot be overridden. It can be ignored, but then the bot isn't being polite.
djr33
12-14-2013, 10:00 PM
Google "robots.txt" for more information.
[Friendly bots like search engine spiders usually respect this. Spambots and other unfriendly bots would, of course, ignore it. Technically a human could also check robots.txt before browsing a webpage, but that's obviously not something that actually happens.]
If you want people to not follow a link (and want to make them unable to do so) then do not include that link in your page. Simple answer and maybe not what you were looking for, but absolutely true and without an alternative.
Note that one option would be to include something that looks like a link (=blue underlined text?) but has no link associated with it. Maybe you're making a joke website where users would be tricked into trying to click a fake link. (I don't know how effective that would be, but whatever.) Then you could create a fake link. But you can't create a real link and somehow disable it. You can also use "#" as the HREF (URL), which will keep them on the same page. Not very interesting, but perhaps what you're looking for.
Actually, you can disable a link using Javascript (assuming the user has Javascript enabled):
<a href="mypage.html" onClick="return false;">fake link</a>
But they could very easy get around this by copying the URL of the link and going to the page manually.
Javascript is not secure, so that will never prevent anyone from accessing the information, but it could slow them down and confuse users who don't know much about it.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.