From what you write it sounds like Apache isn’t reading/following the .htaccess at all. This can be the case if the AllowOverride
setting is not active for that directory. (See this thread on StackOverflow for more information.)
<Directory /var/www/>
Options FollowSymLinks
AllowOverride All
Require all granted
</Directory>
Setting this (AllowOverride None
-> AllowOverride All
) and restarting Apache should solve the problem.