View previous topic :: View next topic |
Author |
Topic : "HTML question" |
Socar MYLES member
Member # Joined: 27 Jan 2001 Posts: 1229 Location: Vancouver, Canada
|
Posted: Fri Feb 15, 2002 2:40 pm |
|
 |
I am putting an .htaccess file on Gorblimey to prevent outside linking to my images.
This is what it looks like so far:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?gorblimey.com/.*$ [NC]
RewriteRule \.(gif|jpg)$ http://www.gorblimey.com/thief.gif [R,L]
Does anyone know what I would add to that if I wanted to allow certain sites (like ezboard, sijun, ebay, etc) to still link to my images? |
|
Back to top |
|
Pat member
Member # Joined: 06 Feb 2001 Posts: 947 Location: San Antonio
|
Posted: Sat Feb 16, 2002 2:55 am |
|
 |
I'm an HTML idiot, but can't you just lock up your directories containing your images by setting folder permissions? Then set up a single one that's a open for outside access?
-Pat |
|
Back to top |
|
lookitsfrank member
Member # Joined: 09 Nov 2001 Posts: 80 Location: MO, USA
|
Posted: Sat Feb 16, 2002 10:23 am |
|
 |
I'm not sure if you can do that with htmaccess Socar, so you might want to try http://www.anti-leech.com/ to see what they can do for you. as far as I know the service is free. You link to something like http://www.anti-leech.com/?user=Socar&file=0896306 and it redirects you to the image on your server. of course it won't show the URL or anything. I think this would be your best option if you still want certain sites to be allowed to view the images.
Hope this helps,
Frank |
|
Back to top |
|
Kreuze member
Member # Joined: 19 Nov 2000 Posts: 97 Location: Northern NY, USA
|
Posted: Sat Feb 16, 2002 5:03 pm |
|
 |
Hey, all you need to do is add another line for each additional exception, i.e.
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://(www\.)?gorblimey.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(www\.)?sijun.com/.*$ [NC]
RewriteRule \.(gif|jpg)$ http://www.gorblimey.com/thief.gif [R,L]
I assume that's all, if you want me to explain in detail .htaccess and RewriteCond etc. works I can, I don't always come by Sijun that often anymore though.
Cheers, J.K. |
|
Back to top |
|
Socar MYLES member
Member # Joined: 27 Jan 2001 Posts: 1229 Location: Vancouver, Canada
|
Posted: Sat Feb 16, 2002 5:42 pm |
|
 |
Thanks, kreuze...I actually just managed to get it figured out an hour or two ago...forgot to post here and mention it.
Thanks for the help, though |
|
Back to top |
|
lookitsfrank member
Member # Joined: 09 Nov 2001 Posts: 80 Location: MO, USA
|
Posted: Sat Feb 16, 2002 11:07 pm |
|
 |
ack. shows how much I know. oh well, long live the rats! may noone tarnish their image by displaying them elsewhere. |
|
Back to top |
|
|