Running Apache on Ubuntu Precise, with PHP 5.5
Trying to access my var/www/ gives me a 500.
/var/log/apache2/error.log
shows:
/var/www/web/.htaccess:<IfModule>not allowed here
my .htaccess is:
DirectoryIndex app.php <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_URI}::$1 ^(/.+)/(.*)::\2$ RewriteRule ^(.*) - [E=BASE:%1] RewriteCond %{ENV:REDIRECT_STATUS} ^$ RewriteRule ^app\.php(/(.*)|$) %{ENV:BASE}/$2 [R=301,L] RewriteCond %{REQUEST_FILENAME} -f RewriteRule .? - [L] RewriteRule .? %{ENV:BASE}/app.php [L] </IfModule> <IfModule !mod_rewrite.c> <IfModule mod_alias.c> RedirectMatch 302 ^/$ /app.php/ </IfModule> </IfModule> Into my apache.conf I added:
<Directory /> AllowOverride ALL </Directory> And it worked after I restarted Apache.