| phil@1918.com 2006-05-29, 5:40 pm |
| Okay, I'm stumped.
I have what I thought was an easy job to do. I want to keep one site
from pulling a picture from my site.
I already have another rewrite in place to do some watermarking of
other images.
Here's my snippet of rewrite:
RewriteEngine on
#RewriteCond %{HTTP_REFERER} ^http://www.severinfilm.hu/
#RewriteRule .*\.jpg$ /babe_stealer.jpg [R,L]
#RewriteRule ^/watermark.* /babe_stealer.jpg [R,L]
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://mysite.com/ [NC]
RewriteRule ^/watermark.php?image=(babe_.*\.jpg)$
/watermark.php?image=babes/$1 [
R]
RewriteRule ^/images/(babe_.*\.jpg)$ /watermark.php?image=babes/$1
[R]
Although I have the top three commented out right now, they are the
ones that have me confused. All I'm attempting to do is... if the
request comes from that domain, serve up an alternate image, if the
request doesn't come from that domain or mysite, go ahead and watermark
my images.
When I enable the top three lines, all other domains get the alternate
image, not just the one specified. Since I'm on day 2, I know it must
be something easy I'm missing.
Any and all help appreciated.
|