Creating Object-Oriented WordPress Plugins That Implement MVC

I’ll be giving a presentation at the Seattle WordPress Developers Meetup tomorrow about how to write WordPress plugins that are both object-oriented, and implement the Model-View-Controller pattern.

If you plan on attending, you can follow along with the slides and download the lab files.

Grandchild Themes in WordPress

It’s not possible to create grandchild themes in the same way that you create child themes, but you can use a plugin to dequeue/enqueue stylesheets and scripts, and also override the locations of the main query templates.

It’s obviously not the ideal solution, but there are cases where it may be the least-bad one.

Preventing a Plugin from Automatically Updating

In an ideal world you’d never have to fork a plugin, because developers would always make their plugins extensible with hooks, just like WordPress itself does. But unfortunately that’s not usually the case, and it’s sometimes necessary to directly modify a plugin to make it do what you need. In those cases, you want to […]

Continue reading...

Sidestepping the Debate About Quotas

Lately we’ve been having a discussion within the Seattle WordPress Meetup about how to be more inclusive, and welcome people who are traditionally under-represented or discouraged from participating in tech communities. During the discussion, Mark Root-Wiley linked to an article by Courtney Stanton where she describes how she was able to get women to represent […]

Continue reading...

Writing is Better than Talking

Zach Holman explains why textual mediums like chat and e-mail are often better ways to communicate and collaborate than real-time mediums like conference calls and face-to-face meetings, but also recognizes that there are a few situations where the opposite is true. Just one more reason why I strongly prefer working remotely.

Maintaining Personal Integrity in Your Career

Barry Eisler asks some tough questions in this essay on journalistic integrity, and I think they can also be applied to working on the Web, or in any industry. I like to think of myself as having strong standards for what types of clients and projects I take on, but after reading the article, I’m left […]

Continue reading...

Do All Websites Need to be Responsive Right Now?

I agree with the principles behind responsive web design, but I think this is a good thing to keep in mind when talking to clients: Timing is everything. For businesses that are trying to turn a profit, their return on investment (ROI) matters. Although mobile is important, it still amounts to a very small percentage of […]

Continue reading...

GoDaddy.com Doesn’t Protect Customer’s Passwords

Unfortunately from time to time I have the unpleasant task of dealing with GoDaddy in one form or another, and today I noticed another failure with their services that caught me by surprise. If you knew how low my opinion of GoDaddy was to begin with, then you’d realize how bad the problem must have […]

Continue reading...

XML-RPC Enabled by Default in WordPress 3.5

XML-RPC will be enabled by default in WordPress 3.5, but I personally think that’s a bad idea from a security perspective. A fellow Seattle WP developer, Ben Lobaugh, explains why on the Trac ticket.. Luckily, it’s easy to disable it. Just add this to a plugin: add_filter( 'xmlrpc_enabled', '__return_false' ); I’ve added that to my […]

Continue reading...

Designing Object-Oriented Plugins for a Procedural Application

Note: This was originally a post to the Seattle PHP Meetup mailing list, but I’m reproducing it here to generate a discussion about the topic with people outside the meetup. * * * * I write a lot plugins for WordPress, and I like to make them object-oriented, even though WordPress itself is mostly procedural. […]

Continue reading...

Designers Shouldn’t Write Code

A discussion came up recently on the Seattle WordPress Meetup discussion board that hits on a big pet peeve of mine — designers writing code. After replying with my own thoughts, I wanted to see what other people were saying about the topic, so I did some searching and came across this essay by Davide Casali. […]

Continue reading...

(Well Organized) Options, Not Decisions

The “Decisions, not options” philosophy argues that giving users too many options can make tweaking a piece of software a difficult and frustrating experience. When a user wants to make a small change, and they find themselves presented with five pages of disorganized options, many will simply give up rather than wade through each one […]

Continue reading...

Don’t Move wp-config.php Outside the Document Root

Most WordPress security guides recommend moving wp-config.php outside of the Apache document root in order to prevent the database password being exposed if the PHP engine fails to parse the file, or from being readable to infected scripts running in the domain. Despite the conventional wisdom, though, this technique doesn’t solve those problems, and can actually […]

Continue reading...

Unexpected Results When Adding Months To a Date

When adding or subtracting months to a date in PHP, you’ll get some uninuitive results in some cases. For example, strtotime( ‘+1 month’ ) will return the timestamp for July 1st when it’s executed on May 31st, instead of the expected June 30th. This is because a “month” is a fuzzy metric (i.e., some months […]

Continue reading...

WordPress Bug Causes Error in XML-RPC Clients

I’ve been having a hard time figuring out an error that a client’s been getting in the Android and iOS apps for WordPress, but finally found the reason. The problem was that, when adding new posts with images, the post would be saved and the image would be uploaded and attached to the post, but […]

Continue reading...