I am working on a site that depends on the following htaccess file to create something of a virtual directory structure by redirecting to an index.php whenever the specified url doesn't exist on the system.
AddHandler php5-script .php
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?p=$1 [L,QSA]
That seems to work fine on the client's existing server. It invisibly redirects things like domain.com/checkout to domain.com/index.php?p=checkout
My problem is that on my local development environment, this causes any non-existing url like that domain.com/checkout, or even the root domain.com to DOWNLOAD the index.php
If I try to load a specific file that exists in the website such as domain.com/index.php then it parses and displays in the browser properly.
In case it matters, my development environment is configured with a Virtual Host on Zend Server Community Edition.