How to Prevent Bandwidth Theft (or Direct Linking)
The Right-Click Block., Changing Filenames., Changing Images., Mod Rewrite., HTML Encryption., Htaccess file., PHP combined with Mod Rewrite.
Step-by-Step Guide
-
Step 1: The Right-Click Block.
This is a simple JavaScript code that goes directly into each of your pages.
It disables the right-click (or copy) function.
You can prevent a small amount of direct linking by using a right-click block.
You can find a free right-click block code from the JavaScript Source. -
Step 2: Changing Filenames.
You can prevent some direct linking by periodically changing the names of your files, folders, and images.
The more often you change them, the less people can direct link successfully from you. , If you know the images that are being direct linked to, do not change the filenames of them, but change the images themselves.
Change each direct linked image to an advertisement for your site. , The most effective way of stopping direct linking.
You must have your own domain, AND your webserver/host must support Mod Rewrite. , By encrypting your HTML, people will have a very hard time reading your source code.
This is a great alternative if your webhost does not support Mod Rewrite.
There are hundreds of programs that allow you to encrypt your HTML, but most of them charge a small fee.
There is good news, though.
I've found a JavaScript-based encryptor that you can use for free at HTML Encryption Utility. , A good method to stop Hotlinking------------------------------------------------------------\Direct Linking.
It can also do many other things but generally you should check with your ISP before setting this up , Random data, combined with HTTP Referer validation is the only sure-fire way to completely secure your images from direct linking.
Ex: /images/robinwilliams0205.jpg?rand=592603759 -
Step 3: Changing Images.
-
Step 4: Mod Rewrite.
-
Step 5: HTML Encryption.
-
Step 6: Htaccess file.
-
Step 7: PHP combined with Mod Rewrite.
Detailed Guide
This is a simple JavaScript code that goes directly into each of your pages.
It disables the right-click (or copy) function.
You can prevent a small amount of direct linking by using a right-click block.
You can find a free right-click block code from the JavaScript Source.
You can prevent some direct linking by periodically changing the names of your files, folders, and images.
The more often you change them, the less people can direct link successfully from you. , If you know the images that are being direct linked to, do not change the filenames of them, but change the images themselves.
Change each direct linked image to an advertisement for your site. , The most effective way of stopping direct linking.
You must have your own domain, AND your webserver/host must support Mod Rewrite. , By encrypting your HTML, people will have a very hard time reading your source code.
This is a great alternative if your webhost does not support Mod Rewrite.
There are hundreds of programs that allow you to encrypt your HTML, but most of them charge a small fee.
There is good news, though.
I've found a JavaScript-based encryptor that you can use for free at HTML Encryption Utility. , A good method to stop Hotlinking------------------------------------------------------------\Direct Linking.
It can also do many other things but generally you should check with your ISP before setting this up , Random data, combined with HTTP Referer validation is the only sure-fire way to completely secure your images from direct linking.
Ex: /images/robinwilliams0205.jpg?rand=592603759
About the Author
Justin Cooper
Brings years of experience writing about organization and related subjects.
Rate This Guide
How helpful was this guide? Click to rate: