I need to allow all userdir
(host.com/~user
) to override options in their .htaccess
, such as php_value
. Where do I configure Apache to AllowOverride
?
3 Answers
You cannot set it inside <Location> or similar blocks. So you must work around it. In my default config the following is used, this seems to be a useful way of doing it (of course you need to adapt the path if you change the UserDir path, too)
<Directory /home/*/public_html>
AllowOverride FileInfo AuthConfig Limit
Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
</Directory>
This depends on your setup. In order for the latest Debian/Apache2 to access http:// host /~user, the "userdir" module must be enabled. You will need to edit this module's configuration file to configure AllowOverride:
vi /etc/apache2/mods-enabled/userdir.conf
Apache will need restarted after this update:
sudo service apache2 restart