Welcome to WebmasterWorld Guest from

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

Allowing one image to be hotlinked

Using mod_rewrite to allow one image to be linked



6:01 am on Dec 26, 2002 (gmt 0)

10+ Year Member

Hello all,

I'm using mod_rewrite to prevent bandwidth theft and hotlinking of my graphices and images. However, I also have an RSS feed, and I want to be able to write an exception in my htaccess file to allow the RSS logo image for my feed to be remotely linked. Is there a way to do that? Appreciate any help :D


6:18 am on Dec 26, 2002 (gmt 0)

WebmasterWorld Senior Member jdmorgan is a WebmasterWorld Top Contributor of All Time 10+ Year Member


Sure, just precede your remote-linking-block rewrite rule with an exclusionary RewriteCond:

RewriteCond %{REQUEST_URI}!allowed_image\.gif$

This will be in addition to the RewriteCond(s) that allows access if the referrer is your own domain, is blank, or is a known allowed entity such as the Google or WebHippo cache, or the Google or AltaVista page translator.



4:23 pm on Dec 26, 2002 (gmt 0)

10+ Year Member

Thanks! I knew there was a commandline for it, just didnt know the correct format. Happy New Year :D

Featured Threads

Hot Threads This Week

Hot Threads This Month