I run the following url:
http://localsite/index.php/foo/bar
index.php is executed and outputs variable:
$_SERVER[SCRIPT_FILENAME] = E:/path/to/file/index.php
mod_rewrite in Apache is disabled.
Who rewrites the rule?
Or what happens?
How index.php is found? Why apache decided to run it?
My configuration: Windows Vista, Apache Apache/2.2.14 (Win32) PHP/5.3.1 (with php module).
(Indeed the problem is the rule is actually rewritten before mod_rewrite - this is when mod_rewrite is enabled. This causes that RewriteCond %{REQUEST_FILENAME} !-f
is always false, because /foo/bar
is trimmed before RewriteCond
).