WordPress is a very popular blog software for many different reasons. In addition to being free, versatile and extremely user-friendly, WordPress is among the most stable of the available blog platforms. Still, there are times when you may have to troubleshoot a WordPress problem.
Identify the problem. You need to know whether the problem is with a WordPress plug-in, Theme or during installation for example, or with a built-in WordPress feature such as the text editor. Write down the error message you receive, or the incorrect behavior you observe.
This article contains information on solving common problems, dealing with comment spam and even troubleshooting problems with design and layout, for detail troubleshooting problems please visit WP Troubleshooting.
Troubleshooting during Installation
During installation, different problems may arise. If you are familiar with them, you may sort them quickly, without hunting around for solutions.
Problem: Headers Already Sent
Sometimes, when you point your browser to the blog, you may get an error that displays a headers already sent message on your page. The whole page may look scrambled and it will not function.
WordPress uses PHP session functions. If anything is displayed before these session functions, which may even be a blank space, then the session functions will not work properly because your browser has already received all headers and it starts displaying the output. In such circumstances, this error may occur.
You have to figure out where the error has occurred. Most of the time, it is a file that you have edited manually. If you remember, you edited the
wp-config.php file while installing WordPress. Open the file with your text editor and make sure that there is nothing before the
<? at the first line and after the
?> at the last line. Now save this file, upload it to your WordPress directory, and refresh your page again.
Problem: Page Comes with Only PHP Code
This could only happen when your server cannot parse PHP properly. This is a problem of your server configuration; either PHP is not installed on your server or it is not configured to function properly. To solve this problem, contact the system administrator for your server or try installing PHP.
Problem: Cannot Connect MySQL Database
If WordPress cannot connect to the MySQL database, it shows a page like the following error:
To solve this problem, open your
wp-config.php file and check whether the database parameters are correct. If you are sure that these settings are fine, please check if the MySQL daemon/service is running properly. If MySQL is not running, run this service. If MySQL was running, try restarting the service.
In MySQL version 4.1 and later, password encryption settings have been changed a bit, so PHP cannot connect to some versions of MySQL. If you are sure that your database parameters are fine and MySQL is also running, then connect to MySQL using your MySQL command-line tool and apply these commands:
set password = OLD_PASSWORD('your_current_password');
This will use old encryption of passwords so that PHP can connect to MySQL. For example, let’s assume my current database password is
root with new encryption settings. I want to change it to old encryption settings.
Following are some basic and common problems that you may face while using WordPress.
Problem: Cannot See Posts, All It Says is Search Doesn’t Meet Criteria
This could happen because of caching. For example, you have searched once and WordPress stored the search result inside its cache. So every time you visit the page you see the old result. You can solve this problem by clearing the cache and cookies from your browser. For this problem, you may also check
index.php for errors.
Problem: I Want to Make My Blog Totally Private
If you are running your blog for a personal and private group or for your own official department so that only members of your group can see it, then you would want to secure it with some kind of authentication. WordPress has no built-in facility to do it. All you have to do is modify your
.htaccess file to enable basic HTTP authentication. For that, you have to create the
htpasswd file using the
htpasswd command in Linux. If you are using Windows, then search in Google for
htpasswd.exe and download it from a reliable location.
Let’s create the
htpasswd file by applying the following command in your command line:
htpasswd -cm .htpasswd myusername
htpasswd command is a command-line tool available in all Linux distributions by default. Immediately after applying this command, the command-line tool will prompt you for a password; type your password. Please note that an
htpasswd file containing the encrypted password has been created in the current working
directory for user ‘username’. Copy that file to your WordPress folder. The
htpasswd file itself is of no use, until you tell Apache what to do with it. So let us create a
.htaccess file in your WordPress folder with the following content, which will tell Apache to turn on basic HTTP authentication using that
AuthName "Restricted Area"
Save this file inside your WordPress directory as
.htaccess. Now whenever you browse this WordPress URL using your browser, it requires the username and password that you created previously. You must supply the absolute URL of the
htpasswd file in the
.htaccess file; it will not work with a relative URL. For example, if your WordPress folder is located inside the
/home/youraccount/public_html/wordpress folder, then the location of the
.htpasswd file should be
If you have trouble retrieving this absolute path, then please don’t worry. Create a PHP file inside this WordPress folder with the following code:
<? phpinfo(); ?>
Now run this file. You will see a page with a lot of text. Search for the text
_SERVER["DOCUMENT_ROOT"], and you will find the absolute URL of this folder on the right-hand side of it.
Problem: I Don’t Receive The Emailed Passwords
This problem may happen if your web server has no SMTP server installed, or if the mail function is explicitly disabled. Please contact your system administrator or try installing sendmail (or any other mail server) properly. It should work.
Problem: I Am Getting A Lot of Comment Spam
You have already got an idea how people can misuse some very useful features of a blog engine, like trackbacks and comments, for advertising purposes and spamming.So all you have to do is start fi ghting with spams. No doubt, it’s very tough to make some automated programs or routines that can detect something as spam because spams don’t always fall into a specifi c category. Moreover, spammers are also clever.
For more to detail about getting rid of spammers look at “How to Maintain Your WordPress Site” and “Stopping spam with reCAPTCHA“.
Once WordPress is up and running, people often encounter issues with things like themes. For example, they might want the date show up in the theme and when it doesn’t by default, they can’t figure out why. Other problems might have something to do with folder permissions that prevent them from uploading images.
Put the blog back into the default theme.
Go to Dashboard -> Appearances -> Themes -> Find the TwentyTen theme (or Default Theme) and select activate.
If your current theme has more than one sidebar, I highly suggest moving your custom widgets into the inactive widgets area (careful not to drop them in the available widgets area) to protect them from any possible confusion when the sidebar they are in is not present in the TwentyTen theme. If your current theme is a single sidebar there’s usually no need for this.
Often, you will notice that problems arise for plugins after a large update to the entire WordPress platform. In any case, the following are a few tips to try if you encounter any problems getting your plugins to run. My plugin stops working after an update—Check the Plugin’s website (listed in the Plugin Browser) to see if any known issues exist.
I can’t find the plugin in my Plugin Browser—Make sure you uploaded it to the correct folder: wp-content/plugins.
Check the plugin’s version compatibility—There is a chance that the plugin just won’t work with a new version of WordPress; if this is the case, hopefully, the developer will release an update soon.
My plugin says I don’t have permission to X folder—Permissions are settings on files and folders that either allow or disallow a user to write to them. You can learn more about setting permissions at WordPress Codex.
My plugin should be showing X on my post, but it’s not—Many times, a plugin requires you to place a custom tag within your post to “trigger” the plugin; read the plugin’s installation documentation.
I can’t find the answer on the plugins’ website—A quick google search for “problems installing [PLUGIN NAME] on WordPress” will lead you to an answer. You can also check the forum link on the plugin’s homepage in the plugin directory at http://Wordpress.org/extend/plugins.
Google didn’t give me the answer I was looking for—Search WordPress’s plugin directory for a different plugin.
I hope you also learned that while WordPress can rock your world, It can also be dangerous and should always be handled with care. There are many benefits to using WordPress and some will only be beneficial to plugin developers, while others exist purely as workflow enhancers for content producers.
References and Other Resources:
Digging Into WordPress
Rockstar WordPress Designer
WordPress, Beginner to Master
Create a Universal Slider Manager in WordPress
Creating a Web Server for WordPress, Joomla or Magento
Basic Troubleshooting Steps
How To Troubleshoot Plugins and Theme Installation Problem in wordpress 3.0
22 | Troubleshooting wordpress themes
Basic WordPress TroubleShooting
How To Troubleshoot WordPress Conflicts
How to Install, Configure, and Use WordPress Plugins
Troubleshooting WordPress Plugin and Theme Issues in 4 Easy Steps
Troubleshooting WordPress Problems
Basic WordPress Plugin Troubleshooting
Get free demos for network+ certification and 642-533 exam with 100% guaranteed success. Our best quality 640-760 dumps prepares you well before appearing in the final exam.