on Tue, 9 Dec 2003 12:49:56 +0000 [EMAIL PROTECTED] wrote:
TPrsc> I want to now be able to stop people from linking to the images directly,
TPrsc> and only be able to access the images via my site...
With Apache you can either use mod_rewrite:
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://domain.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.domain.com.*$ [NC]
RewriteRule .*(gif|png|jpe?g)$ - [F]
or more general method (don't know which mod this is):
#prevent refering to my images
SetEnvIfNoCase Referer "^http://www.domain.com/" locally_linked=1
SetEnvIfNoCase Referer "^http://domain.com/" locally_linked=1
SetEnvIf Referer "^$" locally_linked=1
<FilesMatch "\.(gif|png|jpe?g)$">
Order Allow,Deny
Allow from env=locally_linked
</FilesMatch>
both can be added to your .htaccess file.
--
shinE!
http://www.thequod.de ICQ#152282665
PGP 8.0 key: http://thequod.de/danielhahler.asc
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php