2012-01-05
This drove me nuts for about an hour, until I found this stackoverflow post.
Having problems getting .htaccess
to work? I had the same issue and hopefully this will help you.
vi /etc/apache2/sites-available/example
or whatever your sites-available file is called.
<Directory /var/www/example/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
Look for the “AllowOverride
” line and change it from None to All:
<Directory /var/www/example/>
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order allow,deny
allow from all
</Directory>
and then restarting apache with
sudo service apache2 restart
Now apache should read your .htaccess
file in the example directory.