Intermediate
Making PHP Variables Available to Your JS
If you have ever written a plugin that uses any form of Javascript, you will probably have come across the problem of passing configuration options from PHP to Javascript. Take an image slider plugin, such as Soliloquy for example: most likely there is a settings page of some kind that lets the user set the…
Use TidyPHP with Sublime Text 2 for Lightning Fast Formatting
Writing clean code is something you should always strive for in your WordPress projects, and you should always do what you can to adhere to the WordPress Coding Standards. I tested out a really awesome tool today that you should seriously consider adding to your workflow if you are a Sublime Text 2 user.
Introduction to the WP_Error Class
WordPress has a class called WP_Error that provides a really simple way for developers to track errors while processing data. The class mystified me for a long time, but once I figured it out, it is extremely simple to use, and saves a ton of time when attempting to record errors while processing data of…
Add Custom Image Sizes to Media Uploader
One of the most useful functions to both theme and plugin developers, when it comes to working with images, is add_image_size(), which allows you to create additional automatically generated image sizes to the WordPress image upload process.
The add_query_arg() Helper Function
WordPress includes a lot of helper functions that can make your life as a developer much easier. One function in particular that I really love is add_query_arg(), which provides an extremely simply way to append query variables to any URL. Query vars, in case you’re not familiar with them, allow you to perform any number…
Creating WP List Tables by Hand
An Introduction to the Posts 2 Posts Plugin
Build an À la Carte Premium Tutorial Shop
There are a lot of premium membership tutorial sites out there, this one included, and they usually require that memberships purchase a subscription to the site in order to access the premium content. In this tutorial, I’m going to walk you through the process pf creating an À la Carte tutorial site that lets users…
Introduction to the gettext Filter in WordPress
The gettext filter gives us a really easy way to change text anywhere in our WordPress install, including plugins and themes, without ever changing any of the original code. It is a great way to easily customize labels, headings, button text, and any other text we wish to change.
Add Comment Status Links to Comments Menu
I have always thought it was a little odd that the Comments menu in the WordPress dashboard did not have any sub menu items. For example, I think it makes sense to include sub menu items for each of the comment status: Approved, Pending, Spam, and Trash. But since WordPress doesn’t include these, it is…
Loading Scripts Correctly in the WordPress Admin
There has been a lot of talk over the last two days about loading scripts, particularly jQuery, correctly in WordPress themes and plugins, and anyone who follows me on Twitter probably knows that this is an issue I bring up a lot. When providing support for my plugins, I discover themes (and plugins) that are…
Playing Nice with the “the_content” Filter
One of the very first things people tend to learn when writing plugins is how to attach custom HTML to the bottom of their WordPress posts using the filter called “the_content”. This is good, as it is an extremely useful filter, but rarely do tutorials really explain how to use this filter well, and how…
Adding Custom Fields to the Easy Digital Downloads Checkout
Easy Digital Downloads is a plugin I have been building for selling digital downloads through WordPress. It is completely free and very flexible. Due to a large number of actions hooks and filters, there are many ways that you can customize the plugin to best suit your needs. This tutorial will walk you through the…