|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi,
Whats a good way to stop people linking to my server and stealing my files? I dont want anybody to be able to download from my site unless they are currently at my site.
__________________
regards, Fulton |
|
#2
|
|||
|
|||
|
Use mod_rewrite ->
Code:
RewriteEngine On
RewriteCond %{HTTP_REFERER} !^$ [NC]
RewriteCond %{HTTP_REFERER} !^http://yoursite.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.yoursite.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://yoursiteip.*$ [NC]
RewriteRule /*$ http://www.yoursite.com/ [R,L]
This will protect your images and files from being used outside your site - it essentially stops hotlinking. Change yoursite to your domain name in each case and yoursiteip to the ip address of your server that your domain name resides on...
__________________
~ Joe Penn We work for free to help make this a valuable resource on the internet. Do you appreciate the help - did we provide help that will help you prosper and help that has contributed to sharpening your current skill set? Show your appreciation and purchase something from our Amazon Wishlist's - it's simple and a great way to say thank you. |
|
#3
|
|||
|
|||
|
Joe!
Quote:
Where am I goning to put these? Please show me. Thanks, |
|
#4
|
|||
|
|||
|
I think you can create an .htaccess file and put those lines in it. if not I think you need to insert them into your httpd.conf.
correct me if wrong Joe
__________________
-- Jason |
![]() |
| Viewing: Dev Articles Community Forums > Programming > General Programming Help > Stop people leeching my files |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|