You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Andrea Rossignoli <so...@polin.it> on 2003/01/21 13:07:35 UTC

[users@httpd] mod_rewrite infinite loop

Hi,
usually I use this trick to avoid infinite loop when parsing some rules:

This is only an example to demontrate what happens:

# /.htaccess
RewriteEngine On
RewriteCond %{REQUEST_URI} !/sub_dir [NC]
RewriteRule ^(.*)$ /sub_dir/$1 [L]

I had to add the RewriteCond to avoid an "infinite loop" from the rewrite
parser because I used (.*) in the line three.

Is it the right approach or is there some flag that I can add to avoid to
use the RewriteCond line ?


Thanks,
$Andrea


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org