Debugging is without question not one of the more pleasurable parts of the coding process. When things don't work, you'll often find yourself wondering "what was I thinking when I wrote this!" Throw a few more people in the mix, and things get even more complicated and messier.
Having the proper tools to do the job will make your life easier; a lot easier.
A good editor and a PHP debugger will go a long way, but at some point, you'll need specialized WordPress tools like the plugins listed below. Trust us they'll save you time, money and sanity.
The good news is that all of the plugins in the list below are free and only one has a paid-for version.
We're not saying that to brag, that we made sure you don't have to pay anything. Quite the contrary we'd gladly include some paid-only plugins, but there are no such plugins when it comes to developing.
No actually, it's not.
This is a textbook example of what happens when enthusiasm runs out - plugins get obsolete, forgotten and are left unmaintained.
Time is not free, and money has to come from somewhere. That's why many great debugging plugins haven't been updated in years.
Their authors simply lost the initiative and since there's no money involved they turned to other plugins.
A story for another article perhaps, but also a reminder that 'free' is not necessarily the best option.
"Real developers don't use var_dump and die to debug." - That paraphrased sentence can often be heard in the forums and comments.
I completely disagree with that but can easily correct the sentence - "Developers that don't work in the real-world never use var_dump and die to debug."
Once you work in a properly set development environment with a debugger and the ability to step through code and inspect variables you realize how non-effective the var_dump method is, especially if you work on a more complicated project.
And yes, it would be perfect if you always had that kind of environment and setup available. But you don't! And you won't have.
Real-world situations sometimes call for the var_dump approach. Dirty, frustrating at times and limited but also something that's always available, sets up in seconds and just plain works. So don't be ashamed or troubled if you sometimes use it. We all do.
Not a plugin but we'll still remind you of the various WordPress constants that aid debugging and that go beyond the WP_DEBUG one that everyone uses.
Read the short and to-the-point codex article on debugging to familiarize yourself with them.
Now, let's get started with the list below.
A new kid on the block and just for that we'll give it the first spot.
Nobody can say the world of debugging tools is an exciting one but this plugin definitely brought something new to the table.
It magically (ok, not really but it is fun) and semi-automatically finds problematic plugins by systematically disabling them and asking you if the problem is still visible or not.
By eliminating plugins one by one you can get to the problematic ones fairly quickly thanks to a decent GUI.
The best thing is there is no limit on the type of problems you can solve. Since you're the one saying if the problem is solved or not you can fix CSS issues, JS conflicts, white screens - everything!
A unique and well-executed idea!
Activation functions for themes and plugins are getting more and more complicated.
From creating custom tables to importing demo content - things are genuinely going beyond just setting up some default options.
WP Reset helps you in those situations by resetting the WP installation to default values so you can test your activation functions over and over again without having to reset and set it up manually every time.
It’s also very helpful when you mess WP up and quickly need to get It back to a functional state.
WP Reset supports WP-CLI for those who prefer working with the keyboard and has some exciting features announced for future versions.
Debugging cron tasks can be a full-blown nightmare!
You can get away with var_dump in many cases but when it comes to cron tasks you need a reliable plugin to help you out.
Cron Manager offers everything you need from viewing the schedule and hooked functions to altering the schedule and manually running tasks to test them.
GUI is decent and it just plain works. There's even a paid version if you need more functions like logging and performance stats. Don’t work with cron tasks without it.
Unfortunately, GoDaddy is no longer taking care of this plugin (seems to be their modus operandi to abandon projects) and hasn't updated it in more than three years.
However, when it comes to debugging slow sites, it's still one of the fastest ways of identifying plugins that are causing problems and hogging resources.
If you're developing code that's semi-decent, you won't need this plugin in a local environment because you should know what's going on with your code, and for local environments, there are far better profiling tools.
However, when a client says their site is slow and TTFB is five seconds because of 50+ plugins installed P3 is your best bet to get to the culprit.
Another plugin "not used by real developers" but by those who live in the real world.
WordPress recently upgraded the built-in code editor, so it's much more usable, but AceIDE still has a lot to offer.
In a nutshell, it's a full blown file editor inside WordPress. When you don't have FTP access and need to fix a thing or two, it's a lifesaver!
If file permissions allow it, you can edit any file inside the site's root folder, not just plugin and theme files.
It also boasts numerous code editor features you might not expect like the color picker and a reasonably useful code auto-complete function.
Don't be fooled by the name of this plugin. It really doesn't do it any justice.
It does show queries related information, but it also has fifteen other tabs showing more info about any page that you can think off. Info is available on all admin and front-end pages.
It doesn't matter what you're developing with WordPress; you need this plugin. Just install it by default without thinking and next time you ask yourself any questions about the current page you're on it'll give you an answer.
From transients, DB queries, conditional functions, language, hooks, and actions to template parts, JS and CSS files - it knows everything.
So, why mess with something for an hour when you can get it done in ten minutes?
That’s what proper development and debugging tools are all about. Saving time and nerves.
Sure, you can live without them but life is so much easier with them!
Got a favorite tool you use all the time that we didn’t mention? Let us know in the comment section below and we’ll add it to the list.
Subscribe to my Updates!
Enter your name and best email address below to subscribe to bi-weekly news, the latest blog posts, and special offers.