PDA

View Full Version : Website people, help needed


Wossi
19-10-2007, 09:10
I'm trying to create a .htaccess file to only allow certain sites to use my images from my site. I think it goes something like this:

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?boat-drinks.co.uk/.*$ [NC]
RewriteRule \.(gif|jpg|png)$ http://www.somesite.com/nasty.gif [R,L]

Is this correct as an example? Also I assume I would just copy the third line for each site I visit?

Daz
19-10-2007, 10:02
http://www.thesitewizard.com/archive/bandwidththeft.shtml

Try that :)

[edit]Or if you want to block a specific domain, these guys have a good example:

http://www.bylandwaterandair.com/extras/code/htaccess_single_domain.php

Wossi
19-10-2007, 10:26
Cheers Daz, finally got it sorted. I hope http://www.wossi.co.uk/smileys/crossfingers.gif