Hellos friends,
I have migrated wordpress site, when i run this on my Ubuntu local host the Home page running but other pages like blog,contact-us,services these pages not running,when i click on it then it shows me the given error
Not Found
The requested URL /wordpress-4.7/wordpress/about-us/ was not found on this server. Apache/2.4.18 (Ubuntu) Server at localhost Port 80
this type of error message has been display i have using Ubuntu 16.04 Os In wordpress dashboard the pages are available but it is not running. Any solution please share. Thanks in advance..
Hellos friends,
I have migrated wordpress site, when i run this on my Ubuntu local host the Home page running but other pages like blog,contact-us,services these pages not running,when i click on it then it shows me the given error
Not Found
The requested URL /wordpress-4.7/wordpress/about-us/ was not found on this server. Apache/2.4.18 (Ubuntu) Server at localhost Port 80
this type of error message has been display i have using Ubuntu 16.04 Os In wordpress dashboard the pages are available but it is not running. Any solution please share. Thanks in advance..
Check the following steps.
1) add WP_HOME or WP_SITEURL in wp-config.php example bellow.
// for who are using virtualhost
define('WP_HOME', 'http://example.fmt');
define('WP_SITEURL', 'http://example.fmt');
if use localhost
define('WP_HOME', 'http://localhost/yoursite');
2) check .htaccess file. If you have no .htaccess file in your directory add the following code in the .htaccess in root folder in your site.
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
3) enable mod_rewrite for php in ubuntu
sudo a2enmod rewrite
sudo gedit /etc/apache2/apache2.conf
change near <Directory /var/www/>
AllowOverride none to AllowOverride All
sudo service apache2 restart
4) See debug log. If any permission related issue occur, this will let you know
tail -f /var/log/apache2/error.log
5) Keep folder permission
sudo chmod -R 777 /var/www/html/yourwebsiteroot
Note: always try to use virtualhost.