httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Cramblett <>
Subject [users@httpd] Configuration issue with mod_rewite
Date Tue, 26 Mar 2013 17:18:26 GMT
I seem to have a configuration problem in relation to mod_rewrite.
The issue appears to be that once the rewrite happens successfully the
request is some how overwritten by an operation following the rewrite.
 I am not certain what the "following" operation is at this time.

The initial request is to the root of the server which opens the index
file, index.php

Next, index.php is programmatically requesting "/setup" via php redirect

Then, "/setup" is rewritten to "/setup/installer.php" via a mod_rewrite

Finally, the path is some how overwritten again to use the directory
index and the server tries to load "/setup/index.php"

Here is the virtual host config for this application:



   DocumentRoot "/var/www/Phraseanet/www"

   <Directory "/var/www/Phraseanet/www">
       DirectoryIndex index.php
       Options +Indexes +FollowSymLinks -MultiViews
       AllowOverride All


Here is the rewrite rule (I removed several other rules for now to
make it easier to troubleshoot):

<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule ^setup/.*$              /setup/installer.php [L]

Here is the trace output from apache:

[perdir /var/www/Phraseanet/www/] strip per-dir prefix:
/var/www/Phraseanet/www/ ->
[perdir /var/www/Phraseanet/www/] applying pattern '^setup/.*$' to uri ''
[perdir /var/www/Phraseanet/www/] pass through /var/www/Phraseanet/www/
[perdir /var/www/Phraseanet/www/] strip per-dir prefix:
/var/www/Phraseanet/www/index.php -> index.php
[perdir /var/www/Phraseanet/www/] applying pattern '^setup/.*$' to uri
[perdir /var/www/Phraseanet/www/] pass through /var/www/Phraseanet/www/index.php
[perdir /var/www/Phraseanet/www/] strip per-dir prefix:
/var/www/Phraseanet/www/setup/ -> setup/
[perdir /var/www/Phraseanet/www/] applying pattern '^setup/.*$' to uri 'setup/'
[perdir /var/www/Phraseanet/www/] rewrite 'setup/' -> '/setup/installer.php'
[perdir /var/www/Phraseanet/www/] internal redirect with
/setup/installer.php [INTERNAL REDIRECT]
[perdir /var/www/Phraseanet/www/] strip per-dir prefix:
/var/www/Phraseanet/www/setup/index.php -> setup/index.php
[perdir /var/www/Phraseanet/www/] applying pattern '^setup/.*$' to uri
[perdir /var/www/Phraseanet/www/] pass through

If i request the page "setup/installer.php" directly, the page loads fine.


David Cramblett

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

View raw message