I'm running a LAMP server on Fedora 13 that's working fine; however, I just added an ".htaccess" file to my current site's docroot folder that is being completely ignored.
I've tried half a dozen different tests, including this one:
RewriteEngine on RewriteBase / RewriteRule ^.*$ index.php But images and all other pages load fine, and non-existent files still 404. I also tried this:
order deny,allow deny from all But every page still loads just fine. Again the .htaccess file is simply ignored 100%.
We put our virtualhost records in /etc/httpd/conf.d/virtual.conf. It looks like this:
NameVirtualHost * <VirtualHost *> ServerName intranet DocumentRoot /var/www/default <Directory "/var/www/default"> Options FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory> </VirtualHost> <VirtualHost *> ServerName ourwebsite.com DocumentRoot /var/www/html/ourwebsite.com/docroot <Directory "/var/www/html/ourwebsite.com/docroot"> Options FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory> </VirtualHost> What else could be causing our server to completely IGNORE the .htaccess file??
Edit:
I changed the .htaccess file to above to better demonstrate that my changes are being ignored. Note that I tried the exact same .htaccess file on the production server and it worked fine.
Edit 2:
OK, I have new information! Just for testing purposes, I went through and temporarily changed EVERY "AllowOverride" directive to AllowOverride All. I figured out that the very first Directory entry seems to overpower all others:
<Directory /> Options FollowSymLinks AllowOverride None </Directory> When I changed that to AllowOverride All, my .htaccess files begin taking effect. It's like all the other AllowOverride All directives in my config files are being ignored!
What Gives??