In the first article of this series, we looked at how a boilerplate can improve your development efforts by providing a foundation off of which your project can be built.
Ideally, boilerplates should provide just enough of a framework to get started while letting you focus on the specific business logic, core need, or domain-specific code that you need to write.
Specifically, we took a look at the WordPress Widget Boilerplates and the WordPress Plugin Boilerplate. In this post, we're going to take advantage of the Plugin Boilerplate to write our own plugin in order to see how Boilerplates both lay the foundation for writing good code, and how we can use it as a starting place for our future work.

In the first article of this series, we looked at how a boilerplate can improve your development efforts by providing a foundation off of which your project can be built.
Ideally, boilerplates should provide just enough of a framework to get started while letting you focus on the specific business logic, core need, or domain-specific code that you need to write.
Specifically, we took a look at the WordPress Widget Boilerplates and the WordPress Plugin Boilerplate. In this post, we're going to take advantage of the Plugin Boilerplate to write our own plugin in order to see how Boilerplates both lay the foundation for writing good code, and how we can use it as a starting place for our future work.Read More…

Over the past five to ten years, building sites and applications for the web has become much more complex than much of the stuff that people were building in the 90's. Long gone are manually creating sites using uppercase HTML, table-based layouts, and ugly JavaScript to make some type of cute animation happen on a page.
Now we've got a variety of technologies, frameworks, and languages all of which work together to help us build full on software applications that run within a browser.

Over the past five to ten years, building sites and applications for the web has become much more complex than much of the stuff that people were building in the 90's. Long gone are manually creating sites using uppercase HTML, table-based layouts, and ugly JavaScript to make some type of cute animation happen on a page.
Now we've got a variety of technologies, frameworks, and languages all of which work together to help us build full on software applications that run within a browser.Read More…

On Wptuts+, we talk a lot about how to achieve certain things using WordPress, how to apply practical tips within WordPress projects themselves, but one overlooked area of working with WordPress is bringing aspiring developers up-to-speed on how to quickly get started with building WordPress-based products.
Sure, there are a lot of guides for beginners that are out there, but what about experienced developers who've yet to really hop over into WordPress, or who have worked in environments like .NET or Rails before but are now faced with the task of building something for WordPress?
In this post, we're going to look at some general, educational, and development related tips that are geared towards the experienced developer in order to bring them up to speed in WordPress development.

On Wptuts+, we talk a lot about how to achieve certain things using WordPress, how to apply practical tips within WordPress projects themselves, but one overlooked area of working with WordPress is bringing aspiring developers up-to-speed on how to quickly get started with building WordPress-based products.
Sure, there are a lot of guides for beginners that are out there, but what about experienced developers who've yet to really hop over into WordPress, or who have worked in environments like .NET or Rails before but are now faced with the task of building something for WordPress?
In this post, we're going to look at some general, educational, and development related tips that are geared towards the experienced developer in order to bring them up to speed in WordPress development.Read More…

Hi, my name is Tom McFarlin, and, in this four-part mini-series, we'll be discussing advanced WordPress plugin development. Specifically, we'll be building a plugin that allows us to pull in tweets for individual posts. Let's get started!

Hi, my name is Tom McFarlin, and, in this four-part mini-series, we'll be discussing advanced WordPress plugin development. Specifically, we'll be building a plugin that allows us to pull in tweets for individual posts. Let's get started!Read More…

In the first post in this series, we took a look at the variety of emails that WordPress sends depending on how it's used. We also discussed how it's possible to customize emails that WordPress sends without actually having to outsource the functionality to third party services.
We also reviewed the various filters that WordPress provides for hooking into the system in order to customize our emails; however, because the number of emails that WordPress sends is so large, we've opted to take a focused look at comment moderation and comment notification emails.
So in this article, we're going to be building a plugin that will allow us to completely customize the look and feel of comment-specific emails. Ultimately, this should give you some insight as to how the available hooks work, what's required to customize the emails, and how you can take advantage of the WordPress API to customize the content of your emails.

In the first post in this series, we took a look at the variety of emails that WordPress sends depending on how it's used. We also discussed how it's possible to customize emails that WordPress sends without actually having to outsource the functionality to third party services.
We also reviewed the various filters that WordPress provides for hooking into the system in order to customize our emails; however, because the number of emails that WordPress sends is so large, we've opted to take a focused look at comment moderation and comment notification emails.
So in this article, we're going to be building a plugin that will allow us to completely customize the look and feel of comment-specific emails. Ultimately, this should give you some insight as to how the available hooks work, what's required to customize the emails, and how you can take advantage of the WordPress API to customize the content of your emails.Read More…

When it comes to working with emails in WordPress, most users are familiar with the basic features and/or notifications.
Specifically, we're used to seeing emails for:
User registrations
Password reminders
Comment notifications
...and so on.
When it comes to building more advanced themes - or even applications - it's not uncommon to outsource email functionality in order to provide a better experience for our users.
That is to say that if we're going to be emailing them, then we'd like to make the email as good looking as possible. This usually requires that we include consistent branding, a more flexible layout, and a greater number of styled elements.

When it comes to working with emails in WordPress, most users are familiar with the basic features and/or notifications.
Specifically, we're used to seeing emails for:
User registrations
Password reminders
Comment notifications
...and so on.
When it comes to building more advanced themes - or even applications - it's not uncommon to outsource email functionality in order to provide a better experience for our users.
That is to say that if we're going to be emailing them, then we'd like to make the email as good looking as possible. This usually requires that we include consistent branding, a more flexible layout, and a greater number of styled elements.Read More…

On this site, we spend a lot of time sharing information and discussing how to accomplish certain things with WordPress. After all, the purpose of the site is to provide tutorials - that is, we attempt to give practical advice on how to build certain things using the platform.
But development isn't strictly about writing code and building things. It's also about writing quality, maintainable code, refactoring and improving the state of our projects, and generally trying to leave a codebase in a better state than it was when we found it (or when we began creating it).
So rather than focus on how to build something or review any particular code, let's review a few practical tips for writing quality WordPress code.

On this site, we spend a lot of time sharing information and discussing how to accomplish certain things with WordPress. After all, the purpose of the site is to provide tutorials - that is, we attempt to give practical advice on how to build certain things using the platform.
But development isn't strictly about writing code and building things. It's also about writing quality, maintainable code, refactoring and improving the state of our projects, and generally trying to leave a codebase in a better state than it was when we found it (or when we began creating it).
So rather than focus on how to build something or review any particular code, let's review a few practical tips for writing quality WordPress code.Read More…

In this two-part series, we're taking a look at building a case for code comments. In the first article, we covered the server-side by taking a look at PHP. Specifically, we reviewed PHPDoc conventions and how to use them to document templates, functions, and lines and blocks.
In this article, we're going to take a look at client-side languages. Specifically, we're going to look at HTML, CSS, and JavaScript.

In this two-part series, we're taking a look at building a case for code comments. In the first article, we covered the server-side by taking a look at PHP. Specifically, we reviewed PHPDoc conventions and how to use them to document templates, functions, and lines and blocks.
In this article, we're going to take a look at client-side languages. Specifically, we're going to look at HTML, CSS, and JavaScript.Read More…

When it comes to writing code, regardless of the language or platform that's being used, we developers tend to be divided on how much or how little we should comment our code.
On one hand, there are some who believe that code should be self-documenting. That is, it should be written clear enough such that it doesn't need comments.
On the other hand, some believe that everything should be commented. That is, there should be comments for every class, every function, every block, and every line.
Then, of course, there are those who fall in the middle. In fact, some developers only comment areas of their code that may be confusing rather than picking the all-or-nothing approach outlined above.

When it comes to writing code, regardless of the language or platform that's being used, we developers tend to be divided on how much or how little we should comment our code.
On one hand, there are some who believe that code should be self-documenting. That is, it should be written clear enough such that it doesn't need comments.
On the other hand, some believe that everything should be commented. That is, there should be comments for every class, every function, every block, and every line.
Then, of course, there are those who fall in the middle. In fact, some developers only comment areas of their code that may be confusing rather than picking the all-or-nothing approach outlined above.Read More…

When it comes to writing WordPress plugins, there are generally two ways to go about doing so: Object-Oriented Programming and Functional Programming (with Widgets being the exception - we'll cover that later in the article).
Though you generally have people vouching for one style of programming over the other, each presents its own set of advantages and disadvantages.
In this two-part series, Stephen Harris and I are going to break down the two ways that you can go about writing WordPress plugins. Specifically, I'm going to talk about object-oriented programming, and he'll be covering functional programming.

When it comes to writing WordPress plugins, there are generally two ways to go about doing so: Object-Oriented Programming and Functional Programming (with Widgets being the exception - we'll cover that later in the article).
Though you generally have people vouching for one style of programming over the other, each presents its own set of advantages and disadvantages.
In this two-part series, Stephen Harris and I are going to break down the two ways that you can go about writing WordPress plugins. Specifically, I'm going to talk about object-oriented programming, and he'll be covering functional programming.Read More…

When it comes to professional WordPress development, it's imperative that developers understand both actions and filters - that is, it's important to understand WordPress hooks.
Simply put, hooks are what give us the ability to customize, extend, and enhance WordPress through an API in our themes, plugins, and other custom development efforts.
The problem is that these two features of WordPress - arguably the most important aspects of developing for the platform - are either widely misunderstood or completely ignored.
In this post, we're going to take a look at the WordPress page life cycle, understand how hooks work, and review the differences in actions and filters so that we may not only become better theme and/or plugin developers, but also have a deeper understanding of how WordPress works.

When it comes to professional WordPress development, it's imperative that developers understand both actions and filters - that is, it's important to understand WordPress hooks.
Simply put, hooks are what give us the ability to customize, extend, and enhance WordPress through an API in our themes, plugins, and other custom development efforts.
The problem is that these two features of WordPress - arguably the most important aspects of developing for the platform - are either widely misunderstood or completely ignored.
In this post, we're going to take a look at the WordPress page life cycle, understand how hooks work, and review the differences in actions and filters so that we may not only become better theme and/or plugin developers, but also have a deeper understanding of how WordPress works.Read More…

In this series, we're discussing how to implement Ajax in the WordPress frontend. In the first post in the series, we reviewed how Ajax works at a high-level, reviewed how to introduce Ajax into the Dashboard of WordPress, and reviewed the two hooks available for incorporating Ajax into WordPress.
At this point, it's time to actually build something that will demonstrate how we can use Ajax in the WordPress frontend. To do this, we'll be writing our own plugin making sure that we're following WordPress best practices along the way.

In this series, we're discussing how to implement Ajax in the WordPress frontend. In the first post in the series, we reviewed how Ajax works at a high-level, reviewed how to introduce Ajax into the Dashboard of WordPress, and reviewed the two hooks available for incorporating Ajax into WordPress.
At this point, it's time to actually build something that will demonstrate how we can use Ajax in the WordPress frontend. To do this, we'll be writing our own plugin making sure that we're following WordPress best practices along the way.Read More…