5 common WordPress issues and their solutions

wp-issues

While it’s true that learning WordPress is not very difficult at times you may be frustrated because of some unusual errors while developing/maintaining your WordPress website.

Based on my past experience and my clients’ emails, I have gathered a few of those common issues which may occur on a WordPress website and I have also provided the details on how you should resolve those issues. Let’s get started.

 

Problem #1 ‘Error establishing a database connection’

Looks familiar? If any of you have been running a WordPress website for the last few years, I am sure that you must have encountered this issue at least once. Usually, this error is caused by a misconfigured database & it occurs immediately after a change has been made to a database by you or there has been a recent server upgrade by the web hosting company due to which the key values in the wp-config.php file remains no longer synchronized with the old database credentials.

Solution

As I mentioned above the difference between the updated database values and the ones defined in the file wp-config.php varies, you need to access & edit the file wp-config.php and make sure that the below variables have the correct values:

DB_NAME

DB_USER

DB_PASS

DB_HOST

After successfully updating the above variables, your website issue should be resolved. Read more on how to fix the “Error establishing a database connection”.

Problem #2 ‘Internal Server Error’

This issue is by far the most common issue faced with WordPress websites. The most probable reason for the problem “Internal Server Error” could be the misconfiguration between your WordPress website and the server it’s hosted on.

Solution

If you encounter the issue of “Internal Server Error” on your WordPress website, you may consider replacing your .htaccess file with a fresh one. You may download a default .htaccess file from the location https://codex.wordpress.org/htaccess.The other solution could be installing a new WordPress website in another location of your server and copying & replacing the folders ‘admin’ and ‘include’ from the new location to the existing one (the one with error). The idea is to replace the ‘admin’ and ‘include’ folders with the default ones.

 

Problem #3 ‘Warning: Cannot modify header…’

Several times, you may have encountered the error ‘Warning: Cannot modify header information – headers already sent by (…)’.

Solution

The solution to this issue is to remove white spaces from the file ‘wp-config.php’.These white spaces could be at the beginning or end of the file. Removing these spaces would resolve the issue.

 

Problem #4 ‘Getting lots of spam emails’

With the increasing terror of spam and unwanted emails, it has become necessary to take some action in order to make the inbox clean.

Solution

The best solution to the problem of receiving lots of spam emails is to install clever anti-spam plugins like ‘Antispam Bee‘. These plugins add a hidden field to the forms on your WordPress website which users can’t see but spam bots can see and fill as well. The moment this field is filled by them, the spam bots are trapped and bounced away from the registration form.

 

Problem #5 ‘White screen of death’

As the name suggests, this is one of the most horrible kinds of issues commonly faced with WordPress websites. When you encounter this issue, you will come across a blank white screen without any issue or error message.

Solution

There could be multiple reasons behind the issue of the ‘White screen of death’ and so is the case with its solutions. There could be multiple solutions that you could apply when you face this issue. The most common solution to this problem lies in theme fixing. To do this, first of all, you must rename all of your themes and plugin folders and then switch your WordPress website to any default theme like ‘Twenty-Fifteen’.If the issue gets resolved, you may consider installing a new theme and switching back the plugins and themes one by one. The second solution to this problem could be replacing the .htaccess file with the default .htaccess file which you may download from the link https://codex.wordpress.org/htaccess.The third solution to the problem of ‘White screen of death’ is very simple. Sometimes, you may find that your server has both index.php and index.html files, and index.html files, are blank & been given preference by the server to load first, the website shows a blank white screen. If that’s the case, you may want to delete your ‘index.html’ file so that the other file (index.php) file can be executed by the server.