Software Engineering in Web Development, Backend Services, and More

Author: Tom (Page 192 of 430)

Escaping Data in WordPress (And Why It’s Important)

You can read plenty of information about the importance of escaping information in WordPress via the Codex. If you’re new to the topic, I highly recommend it.

If you need a refresher, or are looking for a short description for why this is necessary, consider this the working definition:

For security on the other end of the spectrum, we have escaping. To escape is to take the data you may already have and help secure it prior to rendering it for the end user.

Clear enough, right? And WordPress offers plenty of functions to help with this.

How do we know which one to use, though?

Continue reading

JOIN Two Tables in WordPress

In a previous posts, I’ve talked about how to:

There’s a lot more to do than just viewing the last query and selecting distinct rows, though. For example, you can also JOIN two tables in WordPress without having to write raw SQL.

So to be consistent with some of the previous posts, I thought I’d share how to do this using the WordPress API .

Continue reading

Improved Ajax in WordPress: Procedural Programming

Years ago, I wrote a series of posts for Envato walking readers through how to use Ajax in WordPress.

Then, not long ago, I provided an updated walkthrough of how to do so with better practices (thanks to @gmazzap for the code review on that one).

One purpose of this blog is to provide articles for others who are getting started in WordPress development. That is, I want to share the things I’ve learned to help shortcut others’ learning.

Sometimes, this requires updating old content. Or it requires providing new ways of doing things already discussed.

Case in point: Using Ajax in WordPress.

Continue reading

Selecting DISTINCT Records in WordPress

If you need to write a query against the WordPress database, grab a reference to $wpdb and get to work, right?

In some instances, sure. I’m not opposed to this. After all, the API exists for a reason. But sometimes, I think we bypass built-in APIs. We go straight for $wpdb without looking to see if other hooks already exist.

Distinct

If a hook exists, why not use it? It’s one level of abstraction above the database and it uses the native API.

As mentioned in a previous post, I want to cover a few ways to customize queries that run against the database.

Case in point: selecting DISTINCT records from WordPress. Continue reading

The Spectrum of Open Source Philosophy

To me, one of the most interesting aspects of open source culture is the variations in open source philosophy we all have.

By that, I mean though many of us appreciate what open source has done, we have varying degrees on how much we use it. For example, some people use only open source software. On the other side of the spectrum, some people never use open source software.

Then, as expected, there are a lot of things that sit between these two points. You know: The proverbial gray area.

As of last week, an interest article has been making the rounds about Slack and FOSS projects. I’ll talk about it more in a moment.

But first, since I’ve never written about my own perspective on open source, I thought I might as well try it.

Continue reading

« Older posts Newer posts »

© 2026 Tom McFarlin

Theme by Anders NorenUp ↑