Page 2 of 7

Chatting on WP Round Table

Last night I had a fun time chatting about WordPress, the community and what it all means on the 100th episode of the WP Round Table podcast. I had a great time with Kyle Maurer and Jason Crawford and we spent the better part of the hour we had together talking about giving back to the WordPress community – a topic that I’m always passionate about.

You can watch the full video (about 1 hour long) right here:

Some of the video of me seems to lag a bit at times (due to the generally lower bandwidth speeds in my area), but the audio all comes through just fine.

Thanks to Kyle and Jason for having me!

Create a custom Featured Image box

When building a UI for adding meta data to a post in WordPress it’s always best to stick to the WordPress styling as much as possible. So, if you’re adding an image upload field to a post, it’s often a good idea to use a known UI element such as the Featured Image meta box. This especially useful if you are asking for a ‘secondary’ featured image – such as one that could be used as a post header image, while keeping the default featured image separate for blog listings, etc.

I did exactly that in a recent project where the posts needed a landscape listing image to be displayed in blog listings while the featured image was reserved for social sharing and viewing inside the single post content.

Continue reading → Create a custom Featured Image box

Democratising Podcasting

The WordPress Foundation is a charitable organisation founded by Matt Mullenweg to further the mission of the WordPress open source project: to democratise publishing through Open Source, GPL software.

That is the opening of the WordPress Foundation’s about page and something that is always at the forefront of my mind when building WordPress products.

One of those products that is a passion of mine as a personal side-project, is my podcasting plugin for WordPress dubbed Seriously Simple Podcasting. I originally built the plugin for my church’s website because all of the available podcasting plugins at the time were either too bloated or too under-powered to use effectively. With that in mind, the main thing that separates my plugin from the rest of them is, as the name suggests, the sheer ease of use. My development focus has always been on the user and Seriously Simple Podcasting is no exception in that regard.

But I digress – what I’ve brought you all here for today is actually to say that my podcasting plugin isn’t just an easy to use solution for podcasters to make their content available to the world, but it is also aiming towards the lofty goal of emulating the WordPress project itself by fulfilling the mission of democratising podcasting as an open-source and entirely free product.

Now, to be clear, ‘open source’ does not necessarily imply that the software is free (in fact, the definition given by the Open Source Initiative doesn’t even mention price at all), but this is something that I wanted to do as a way of giving back to the community by making audio publishing just as free and easy as blogging has been made by WordPress.

If you’re interested in joining me on this mission to democratise podcasting then know that the Seriously Simple Podcasting repo on GitHub is always open and ready for your contributions as is the repo for the hugely significant stats add-on. You could even come on board by helping to translate the plugin.

Whether you get involved or not, however, I will continue to work towards the goal of democratising podcasting for everyone and I’d love some company.

A non-developers guide to getting involved in WordPress core development

WordPress core development is an exciting world to explore and I highly recommend that any and all WordPress developers go and jump right in. This post is not for developers though – this post is for those who have strong and valid opinions about WordPress core features, but are not able to contribute to the codebase itself.

If you fall into that category then you might feel somewhat left out and unable to get involved, but I’m pleased to tell you that there is actually a lot you can do.

Provide feedback

WordPress itself is, as we all know, 100% open-source. One of the implications of this is that there is a vast community of people who are able to have a say in what goes in the development of the platform. That community includes you.

So how do you have your say and provide feedback? Some people like to use angry blog post comments or passive aggressive tweets (which usually involve threats to leave/fork WordPress), but I’m sure we can all agree that things like that are completely unproductive. There are, in fact, three primary locations that allow you to easily provide feedback, each with their own focus and purpose:

1. The Make Core blog

Each aspect of the WordPress has it’s own (publicly available) ‘Make’ blog and the core one is right here. This blog contains, amongst other things, updates on core feature development. Each post that includes these updates is also open for commenting, so if you have an opinion about a specific feature then you can easily get involved by simply commenting on the relevant post.

Take the recent oEmbed feature that is going to become available in WordPress 4.4 for example – all of the posts about that feature are open for reading and commenting on the blog. If you would like to influence how the feature is built or if you maybe have a use case that the developers may not have thought of, then the best thing to do is to comment on the relevant post as it is published.

2. The Making WordPress Slack channel

Blog posts comments too cumbersome for you? Want to chat to the developers in real time? Then the Making WordPress Slack channel is perfect for you. Slack is free to sign up for (which you can do here) and it provides a platform where you can have live conversations with a number of key decision makers for the WordPress project.

All Slack conversations are recorded in the channel archive, so if you missed a conversation then you can always go back and have a look at what you missed.

3. The core issue tracker

All of the code that is written for WordPress core is managed through Trac – if you would like to give feedback on the actual code then this is the place to go. It can be a bit daunting (mostly because the Trac UI isn’t super user-friendly), but this is a great place to provide your feedback, opinions and maybe even a patch or two if you’re feeling brave.

Test new features

This should come before you provide feedback, but testing is an incredibly important part of each WordPress release (and indeed the release of any software) – simply using the new features and providing feedback on how it works is more valuable than you might realise.

To make things easy for you, all you need to do is install the WordPress Beta Tester plugin and you will be automatically updated to the latest development version of WordPress that includes all the new features and fixes that are set to be included in the upcoming release. From there, you simply need to try out a few things and see how it works – if anything breaks or if you think something should be done differently, then provide some feedback using any (or all) of the methods listed above.

So that’s it – it really is that easy to get involved in WordPress core development, even if you don’t call yourself a developer.

If you’ve read this and you’re interested in WordPress development, then what are you waiting for? Go forth and test!

My intro slides for WordCamp Cape Town 2015

Last week was the much anticipated WordCamp Cape Town 2015, which was an undeniable success. I’m busy putting down some of my thoughts about the event and the WordPress community in South Africa in general, which I’ll publish in the next week or so, but in the mean time,, here are the slides from my intro session – The WordCamper’s Guide to the Galaxy.

It was a short session (about 10 – 15 minutes), so the slides are admittedly thin, but the point was to give a quick intro rather than a meaty talk. The slides do include, however, a video welcome from Matt Mullenweg (WordPress co-founder) that he sent down especially for our attendees.

And because Speaker Deck doesn’t allow video to be included in slides, here is Matt’s welcome message:

Community is to WordPress as Bacon is to Breakfast

Yesterday afternoon I presented a session on WPSessions that was all about the WordPress community and how we can all engage with it in a more meaningful way. The session went very well and I had loads of fun doing it – a big thanks to Brian Richards for inviting me to speak!

You can watch the session for free right here – it’s a little less than an hour long in total.

I won’t spoil the content for you, but think of this session as a motivational talk that will inspire you to get involved in the WordPress project in a way that is not only relevant to you, but impactful on the broader community. I can’t stress the importance of meaningful community engagement enough, so have a watch of the video and feel free to leave a comment on here.

Getting Started With WordPress Development

Last night I spoke at a meetup of the Cape Town PHP Group. I was speaking alongside the excellent Gareth McCumskey who was giving a run down of what we can expect in PHP 7 (we can expect a lot of awesomeness by the way – you should really check that out).

My presentation for the evening was a primer on WordPress development and a guide on how to bend WordPress to your will (which would have made a way more awesome title for the talk).

The vast majority of the 30 attendees at the meetup were advanced PHP developers who had minimal experience with WordPress development – this gave me a nice opening where I could talk about some of the basics of writing code for WordPress without having to start with the basics of PHP first. It was also relatively intimidating knowing that most of the people in the room were probably more experienced and more qualified developers than myself, but I think I held my own well enough.

My talk was well received and I think I went on for quite a bit longer than I was supposed to, but that was mainly due to so many questions being asked. It was very encouraging to see that there is clearly a significant interest in WordPress development inside the PHP community.

The video and slides for my talk are below, along with a list of useful links that I either mentioned or feature in my slides at some point.

Useful links:

WordPress plugin developer info
All the information you need in order to get your plugin on the WordPress plugin repository.
WordPress coding standards
WordPress has defined coding standards for PHP, Javascript, HTML and CSS.
WordPress Action Reference
An ordered list of (almost) all of the action hooks available in WordPress core.
WordPress Filter Reference
A list of (almost) all of the filters available in WordPress core.
My WordPress plugin template
A plugin template I developed for my own use that helps get a new plugin off the ground with very little effort.
Varying Vagrant Vagrants (VVV)
Varying Vagrant Vagrants is an evolving Vagrant configuration focused on WordPress development.

Whether you were at the meetup or not I would encourage you to dive head first into WordPress development and I’ll happily lend a hand where I can, so get in touch with me in the comments!

Starting a New Chapter

Today is not only my 3 year anniversary of joining WooThemes, but it also marks the first day that I am no longer a full-time developer on the team. This kicks off a significant new chapter in my professional career as it will be the first time since I started working that my job will no longer be 100% focussed on writing software.

My new title at WooThemes is Community Engagement Manager, but titles don’t mean all that much in the WordPress community these days so let me explain that a bit further. I essentially created this position for myself because I saw a need at WooThemes that I wanted to fill.

What is it?

The Community Engagement Manager position exists to manage WooThemes’ relationship with the WordPress community. It will involve engaging with other companies and individuals in the community as well getting involved in practical ways – from events and sponsorships to core contributions, plugin development and engaging in discussions. On top of that, a big part of this position is ensuring that our whole team gets involved in the broader WordPress community on an individual level.

Why does WooThemes need it?

I believe it is incredibly important for WooThemes, as a company, to be more heavily involved in the WordPress community than we are currently. Matt Mullenweg also thinks so and, while this isn’t a quest to tick a box or fill a quota, the principle behind his 5% is to be giving back to the community in a dedicated and intentional manner – this position fills that need at WooThemes.

Why me?

I completely believe in the community and I’ve benefitted so much from it already that giving back in an intentional and direct manner is something that I am totally passionate about. I love what the WordPress community is and what it represents – being the Community Engagement Manager will allow me to tie my work at WooThemes together with my passion for the WordPress community.

What will I be doing?

Seeing as though this is a brand new position at WooThemes, we’ll be figuring a lot of it out as we go, but the overall goal of the position is to move WooThemes to the forefront of WordPress contributions and the community. This will come in the form of active contributions on my part as well as working with each member of our team to get them all to a point where they are actively contributing on a regular basis. I’ll also be working towards getting WooThemes directly involved in community projects (such as CommHub and HelpHub).

I’m very excited for this position – not only because I now get to devote 100% of my time to improving the WordPress community, but also because it will enable WooThemes to become far more effective and present in the global WordPress community.

As a side note, this move is nicely complemented by Bryce Adams moving into a full time development role at WooThemes.

Software development never changes

In the early ’80s, my father trained countless Cobol programmers. A mantra that he always repeated to every single one of his students was this:

A good programmer focuses on getting the code right, while a great programmer focuses on what the users have asked for.

That was over 30 years ago. Around the time BASIC was invented – before C++, Turbo Pascal or Perl even existed and long before PHP, Python, Ruby, Javascript or any language that we actually use today had even been conceptualised.

Jump ahead to 2015.

This week I was interviewed on the WisdmLabs blog about my WordPress development practices. They asked me: What is the difference between a good developer and a great developer?

The answer was fairly obvious to me, not because my father had told me (I never knew he even had that mantra), but because this is just the way I have always viewed things:

A good developer focuses on code, while a great developer focuses on users.

So what’s changed in 30 years of software development?


Sure, we have new technologies available to make things easier – simpler languages, more convenient libraries, new coding standards and more efficient IDEs. But none of that will ever change what the main focus of any software development should always be: users.

If users aren’t at the centre of your development then you’re already doing it wrong.

I should probably point out that the guy in the photo at the top is not my dad – that’s Ken Bowler, a systems programmer from the University of British Columbia circa 1980.

WordPress: Check if user role exists

As part of a recent Sensei update we added some custom capabilities to the editor role, but we discovered that some people have deleted that role from the database as a way of cleaning up unused data on their sites. This meant that our add_cap() calls were causing fatal errors for these sites.

While that is admittedly a fringe case, it’s useful to know how to check if a role exists in the database before you go about manipulating it. It’s actually really easy to do, but WordPress doesn’t have a handy role_exists() function or something similar, so it requires a small amount of custom coding.

Here’s how we added a function like this and solved the problem for ourselves along with the basic usage: