httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marten Lehmann <>
Subject mod_rewrite && apache 2 problem
Date Mon, 20 May 2002 22:54:19 GMT

I've got the following lines in .htaccess:

RewriteEngine On
#RewriteBase /
RewriteCond %{REQUEST_URI} ^/sess/[a-z0-9]{4}/(.*)
RewriteRule ^.* /apps/$1 [L]
RewriteCond %{REQUEST_URI} !^/soap/
RewriteCond %{REQUEST_URI} !^/redirect/
RewriteRule ^.* /redirect/

What they should do is: Rewrite e.g. /sess/0573/ to /apps/ 
and don't allow to be called directly. Grant access to the 
/soap-directory and rewrite everything else to /redirect.

I tried it with RewriteBase and without, with [L] and without, but it 
doesn't work correctly, since the second rewrite-rule is always used 
when calling a /sess/4024/-file. Usually it should stop after [L]. And I 
would like to deny access to /redirect directly, how can I do this? 
Where is my mistake? I'm sure it's correct.

Marten Lehmann

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message