I imported a wordpress production website into my local server to modify it and learn how to wordpress. I use LAMP and my WordPress project is located on a different Hard Drive than my Ubuntu 16.04 partition. But even if I can access to the main page, all the other links (except /wp-admin) are returning a 404 not found error.
As I could read, the problem could be that the .htaccess file was not read by apache2. To enable this option, I needed to enable the plugin rewrite with
sudo a2enmode rewrite and to change in
/etc/apache2/sites-enabled/000-default.conf the :
<Directory /var/www/html> Options Indexes FollowSymLinks MultiViews AllowOverride None </Directory>
<Directory /var/www/html> Options Indexes FollowSymLinks MultiViews AllowOverride All </Directory>
If this may correct the error 404, it creates an internal server error…
Is anyone have an idea of how to handle this problem ?
Thank you !
Read more here: The permalinks in WordPress returns 404