Your New Year’s resolution might have been to start developing for WordPress. However, despite the platform’s ease of use, there’s still a learning curve to master. You’ll find there are plenty of resources available to help you begin, but understanding everything involved could prove challenging. Fortunately, the basics of developing for WordPress are easy to grasp. A number of key elements (such as the way WordPress is coded) can be found on other platforms and coding languages. All in all, getting started with development could take as little as an afternoon. This post will look at the basics beginner WordPress developers need to know, including the fundamentals of the platform. We’ll then explore some key aspects of WordPress, before giving you some insight into how to begin developing for the platform! What WordPress Is (And Why You Should Develop For the Platform) For the uninitiated, WordPress is currently the most popular Content Management System … [Read more...] about Back to Basics: A New Developer’s Guide to Creating WordPress Products
One of the arguments for using WordPress is that affordable help for the platform is easy to find. It’s something I have seen claimed around the web a lot of times and I have made this argument myself, repeatedly. It seems simple enough: WordPress has less of an entry barrier for developers, meaning it’s easier to get into. It also has the largest ecosystem among all content management systems. That should mean a high supply of developers, which should result in low prices. However, it recently occurred to me that I have no concrete evidence to support that claim. Like other people, I simply repeated what I heard elsewhere and what my gut feeling told me. Therefore, I thought it’s time to find out if that claim is actually true. That’s exactly what I will attempt to do with this post. As I’m typing this, I’m not entirely sure yet how I am going to approach that task. I guess we will find out. Some Clarification on the Methodology So, before we get … [Read more...] about Are WordPress Developers Really Cheaper to Hire?
So far in this series on writing WordPress plugins using object-oriented PHP, I’ve focused mainly on testing. This is because a key advantage of object-oriented PHP is that it can be written in a way that is both highly testable and highly reusable. Just using classes doesn’t magically give us this We’ve also not written any code that does something practically useful. The idea is to show how to customize search via the WordPress REST API. The example plugin, at the point where I’ve left off just returns an array of WP_Posts. But, the public API for the system is now fully developed and has tests describing its correct behavior. In my personal journey as a developer, I’ve taken testing more serious and less seriously at times. Right now, I’m in “TEST ALL THE THINGS!!!” mode and one of the reasons I love it is the freedom to refactor. With untested code, it’s hard to refactor as you do not know what the side-effects will be. While … [Read more...] about Advanced OOP: Refactoring Is An Opportunity To Adopt Test-Driven Development
In my last post in this series on advanced PHP object-oriented programming for WordPress development, I walked through refactoring the low-level API of a plugin, using tests to guide the process and make sure everything works correctly. I say “low-level API” because the focus was on the internal of how the system will work. I didn’t cover too much of wiring things together. In this article, that’s where this post picks up. The next step was to create a factory that takes an array of arguments for the REST API to add, and an array of post types — that auto-wires those filters. Test-driven development (TDD) is the practice of writing tests for a change in a code base before actually writing the change. Doing so makes the test the specification that defines if the new feature/ bug fix/ whatever works or not. Existing tests also passing defines if the new feature/ bug fix/ whatever are going to create regression errors or not. Switching to TDD on an existing … [Read more...] about Developing New Features For Extensible WordPress Plugins Using Test-Driven Development