Tom McFarlin

Software Engineering in WordPress, PHP, and Backend Development

Page 285 of 428

Programmatically Set a Default Menu in WordPress

When it comes to building a theme (or any WordPress project that’s going to feature custom menus), there are several options from which we can choose on how to set a default menu.

We can…

  • use whatever WordPress provides,
  • remove the default custom menu,
  • or programmatically set a default menu

The first two are relatively easy to do (as is the third), but I’ve found that in the majority of my work, clients usually want to have a default menu of options relevant to the project at hand if the user doesn’t set one by default.

Continue reading

Outsource WordPress Support (I Don’t, But What About You?)

I recently received a comment on my article on WordPress plugin support (that is, How Much is Too Much?).

Specifically, the comment asked:

So why not just outsource the support e.g. use a service that provides support to plugin end users on behalf of the plugin developers? Seems like that would save the developer a ton of time.

I thought that this was a great question, but as I began to respond, I thought that it may work better as a full post rather than a comment if for no other reason than to more easily share my own thoughts on the matter (but also to gauge other people’s opinions, as well :).

Continue reading

Developer Distractions: The Available Tools

"A computer on every desk in every home"

“A computer on every desk in every home”

When it comes to computing, development, and related technologies, it’s really easy to be inspired by individuals such as Steve Jobs – and many people in our industry are.

I certainly am.

But I also remember, back in the 90’s, reading a lot about Bill Gates, his mission to have a computer on “every desk in every home,” the things they were working on at Microsoft, and certain things about programming that I was too young to really understand (but found interesting, nonetheless).

Recently, I came a cross a really neat interview with Gates from 1986 in which he talks about a number of things – his experience in programming, Microsoft, where computing was headed, and so on.

Continue reading

Mayer For WordPress – Now Available at WordPress.com

I’m proud to announce that, as of today, Mayer is officially for sale on WordPress.com.

This particular release has been a long time coming, so much so that I’ve discussed it a number of times on the blog already:

Of course, after several rounds of beta, code reviews, feature changes, and so on, things are bound to change over the course of development.

But today, Mayer is officially at `1.0` and is ready for purchase.

Continue reading

Separation of Concerns with Queries and Helper Functions

In the previous post, I shared a little bit about the idea of separation of concerns – a concept that’s usually isolated to software development – and one way in which it can be achieved as it relates to working with WordPress templates.

But there’s always more work that can be done to help make our code as modular, reusable, maintainable, and readable (and any other buzzwords that I forgot ;) as it relates to programming projects.

One of the challenges of working in a system like WordPress is that it doesn’t necessarily promote practices that are typically seen in more classical programming environments, but – the way that I see it – we’re doing many of the same things:

  • Solving problems through the use of code,
  • Abstracting reusable components,
  • Querying for information from a database through the use of provided APIs,
  • Keeping areas of the code modular and related to the areas of the application and their best related,
  • …and more.

So why should we avoid trying to apply better programming practices to our code regardless of if it’s a high-end object-oriented application, or – say – a theme with a number of different templates, JavaScript, styles, and queries (and even more things such as post types and taxonomies depending on the nature of your project)?

After all, it’s all code, right?

Continue reading

« Older posts Newer posts »

© 2026 Tom McFarlin

Theme by Anders NorenUp ↑