Category archives: Apache configuration

Solved: WAMP / Apache URL Frustrations

I'm using WAMP Server, mostly configured as-is out of the box, but I was having trouble getting mod_rewrite to behave as expected locally (everything worked fine on a production server).

I have a PHP file located at /ajax/graphs/get-graph.php.

The way this file is normally invoked is via a bootstrap file loaded by /index.php.

I have a .htaccess file at the root with the following rules:

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php [L]

So, basically, when my app requests via AJAX a call to /ajax/graphs/get-graph/ it should be directed to /index ...

Continue reading