nicholas
06-28-2003, 11:46 AM
it can be done with .htaccess files,
heres some info I found, its easy to make a .htaccess file and upload it to the directory where you wish to protect.
Here is an example you can copy for other images and directories
this page this image http://yourdomain.com/images/various/test.jpg
will be protected with this .htaccess file
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://(www\.)?yourdomain.com(/)?.*$ [NC]
RewriteRule .*\.(gif|jpg|jpeg|bmp)$ http://yourdomain.com [R,NC]
Save this file as htaccess.txt, then upload it into the folder where you want the files restricted (usually your images folder).
Rename the file to .htaccess (remember the dot!!) and the file will become 'invisible' to most ftp programs.
Test linking an image from another webpage, forum etc to make sure it works ok.
heres some info I found, its easy to make a .htaccess file and upload it to the directory where you wish to protect.
Here is an example you can copy for other images and directories
this page this image http://yourdomain.com/images/various/test.jpg
will be protected with this .htaccess file
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://(www\.)?yourdomain.com(/)?.*$ [NC]
RewriteRule .*\.(gif|jpg|jpeg|bmp)$ http://yourdomain.com [R,NC]
Save this file as htaccess.txt, then upload it into the folder where you want the files restricted (usually your images folder).
Rename the file to .htaccess (remember the dot!!) and the file will become 'invisible' to most ftp programs.
Test linking an image from another webpage, forum etc to make sure it works ok.