Monday, September 23, 2013

Converting WordPress from Windows to Apache Server Error

Recently I was working with a charity that had a WordPress site running on a Windows server.  The owner decided to change it to an Apache server.  After the conversion he noticed that none of his child pages where linking.  It displayed a very vague error which could have most people changing things they don't need to touch.  In the snippet below, you'll see the code that needs to be changed in your root .htaccess file.  You can basically copy the whole thing and paste it over what's currently in that file.  Happy Coding! ☺

 
# BEGIN WordPress
ErrorDocument 404 /index.php?error=404
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress