httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Slive <>
Subject Re: [users@httpd] mod rewrite question..
Date Wed, 03 Dec 2003 20:25:31 GMT

On Wed, 3 Dec 2003, BOFH wrote:

> In an effort to curb image linking to my website I have put in the
> following in the server wide part of my httpd.conf file:
> RewriteEngine on
> RewriteCond %{HTTP_REFERER} !^$
> RewriteCond %{HTTP_REFERER} !^*$ [NC]
> RewriteCond %{HTTP_REFERER} !^*$ [NC]
> RewriteRule .*\.(gif|GIF|jpg|JPG)$ - [F]
> This works great, however I would like to let a single user link images
> from their web directory.  How would I go about setting up apache to let
> images be linked out of a particular directory structure?  I.E.
> /home/webdocs/userx

Add another RewriteCond.  I think what you are saying is that you want to
exempt one particular directory from these restrictions.  If so, you could
add something like

RewriteCond %{REQUEST_URI} !^/userx


The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message