Skip to content

Instantly share code, notes, and snippets.

@claylo
Created June 14, 2011 03:25
Show Gist options
  • Save claylo/1024252 to your computer and use it in GitHub Desktop.
Save claylo/1024252 to your computer and use it in GitHub Desktop.
Apache example configs for RESTful "routing"
# for you mod_php5 fans
<VirtualHost *:80>
# ...
<LocationMatch "^/(foo|bar|baz)/.*$">
ForceType application/x-httpd-php
</LocationMatch>
</VirtualHost>
# for the PHP-FPM lovers
<VirtualHost *:80>
# ...
<LocationMatch "^/(foo|bar|baz)/.*$">
SetHandler php-fpm
</LocationMatch>
</VirtualHost>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment