If you’re setting up WordPress on a new server you may find that your custom permalinks don’t work and worse changes you make to your .htaccess file are ignored or have no effect. It sounds like you need to modify your VHOST configuration file on your web server.
Modify VHOST to AllowOverride
By default AllowOverride is disabled, this means .htaccess files and files like php.ini are ignored. Even if you enable mod_rewrite using
sudo a2enmod rewrite
your .htaccess will still be ignored.
You’ll want to login to your server (via Terminal / shell) and then each of these commands.
- Nano is my favourite CLI ‘text editor’ so type
sudo nano /etc/apache2/sites-available/default
Look through the file for:
- Ctrl+x and Y to save the file
sudo apache restart(this works for Ubuntu and Apache)
Let me know if you found that Allow Override was set to None and this fixed your problem please.