Tom McFarlin

Software Engineering in WordPress, PHP, and Backend Development

Page 76 of 427

Reading and Understanding WordPress Error Logs, Part 2

Last time, we walked through the following:

  1. configuring debug constants,
  2. locating an error log file,
  3. understanding how to read the log file,
  4. understanding stack traces
  5. understanding how to read the stack

As nice as that is, it’s still important to understand how to write data to error log from a programmatic aspect. That is to say; it’s one thing if your work throws errors, warnings, or notices.

Understanding WordPress Error Logs

It’s another thing if you want to understand how to write information to the file for research and debugging manually.

In this post, we’ll continue doing exactly that to further our understanding WordPress error logs.

[restrict paid=”true”]

Continue reading

The Second Social Media Sabbatical of 2018

As I’ve been writing this post, I’ve felt so pretentious when it comes to using the word “sabbatical” as it relates to something like social media.

I mean, I’ve always associated sabbaticals as something that professors, academic types, religious leaders, and higher-ups take. Not just an average dude who makes a living on the Internet.

Sabbatical or a sabbatical (from Hebrew: shabbat (שבת) (i.e., Sabbath), in Latin: sabbaticus, in Greek: sabbatikos (σαββατικός), literally a “ceasing”) is a rest from work, or a break, often lasting from one month to a year.

But I suppose, by that definition, it makes sense, right?

Anyway, I started the trend earlier this year, it went well, and I want to keep a consistent theme going at least for 2018, so why stop it during just the second time through?

Continue reading

What’s with the ERR_SPDY_PROTOCOL_ERROR?

One of the things that’s often brought to my attention is that people see the ERR_SPDY_PROTOCOL_ERROR whenever they try to access this site.

ERR_SPDY_PROTOCOL_ERROR

I’ve had people respond to links from my newsletter, from links on Twitter, from links from third-party sites, and sharing their experiences when trying to access other sites, too.

The thing is, few people – myself included – seemed to be able to diagnose the problem. (And believe me when I say that I’ve tried a ton of different things to fix it on my end.)

So to the best my ability, I researched the problem, all possible fixes, and thought I’d share what I found here along with the fixes.

Continue reading

Reading and Understanding WordPress Error Logs, Part 1

As we continue looking at what it means to be an independent WordPress developer, the tools needed, and the various strategies that can improve our skillset, I’ve been talking through the various constants, plugins, and tools to help us.

If you’re just stumbling across this post, then I recommend checking out my guide to native WordPress debugging tools as well as the rest of the posts in the series thus far.

After all, I find it important that we’re all working off of the same foundation – or something closely related – when going through this information.

Understanding WordPress Error Logs: Xdebug

Ultimately, using a tool like Xdebug is indispensible, but we have to work up to that (for those who are curious, I wrote a brief guide about this a little over a year ago).

For now though, let’s start with the basics. In the previous post, I left with the following statement:

In the next post, we’ll start looking at what’s necessary to examine the error log that’s generated by WordPress and how to understand the information we see.

And that’s what I want to look at today because, if nothing else, it will give you something practical off of which to work.

Continue reading

What’s the Purpose of a Boilerplate?

Regardless of the library, framework, or code with which you work, you’re likely going to encounter the concept of a boilerplate at some point.

There are a handful of them for WordPress, right 🙃?

But it seems to be an increasingly popular trend that people are creating more and more boilerplates, which isn’t inherently a bad thing, but that there may be confusion as to the purpose of a boilerplate.

The Purpose of a Boilerplate

Photo by NeONBRAND on Unsplash

So, as defined by Wikipedia (which I think offers a great definition):

In computer programming, boilerplate code or boilerplate refers to sections of code that have to be included in many places with little or no alteration. It is often used when referring to languages that are considered verbose, i.e. the programmer must write a lot of code to do minimal jobs.

But notice there’s a phrase that should not be missed. Specifically:

…that have to be included in many places with little or no alteration.

And in some observations I’ve seen within the WordPress economy, at least, boilerplates seem to require that code be removed, modified, or stripped away rather than simply included or added.

That’s what I hope to clarify.

Continue reading

« Older posts Newer posts »

© 2025 Tom McFarlin

Theme by Anders NorenUp ↑