Member
Member
darkufo   28-01-2013, 14:00
#1

Hi,

I've currently got the following in my .htaccess of my zenphoto cache folder.

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?spoilertv.com [NC]
RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?fanshowcase.com [NC]
RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?spoilertv.co.uk [NC]
RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?images.spoilertv.co.uk [NC]
RewriteRule .(jpg|jpeg|png|gif)$ http://spoilertv.co.uk/images/bandwidth.png [NC,R,L]

This blocks all not allowed domained from hotlinking our cache files.

However, what I would like to do is to allow sites to be able to hotlinked our thumbnails. The thumbnail images h have this sort of filename format

filename_100_cw100_ch100_thumb.jpg
filename_100_cw100_ch100_thumb.png

So what I would like to do is to modify the above .htaccess to globally block all access with the exception of the filenames ending in thumb eg _thumb.jpg or _thumb.png

I don't have the first idea about how to write such a rule.

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.