Tom McFarlin

Software Engineering in WordPress, PHP, and Backend Development

Page 161 of 427

Ignore Coding Standards in PHP CodeSniffer

For as much as I talk about writing code that conforms to the WordPress Coding Standards and for using tools such as PHP CodeSniffer, there are times where I’ve found that you need to silence the errors for the sake of something you’re trying to do.

Case in point:

WordPress uses global variables to maintain certain data structures. As per the coding standards, you should not change the values of global variables.

As a rule of thumb, this is true. But what about in the case where you need to make a modification to the admin menu (which uses a global variable)?

Continue reading

The State of HTML5 Browser Support

Knowing the state of HTML5 browser support helps to add points of conversation to the debate between what should be a web application and what should be a native application.

Though I don’t think it’s a debate that will end any time soon, I think it’s a good conversation to have.

But with the incredibly fast advances happening in browser technologies, it’s nice to know what APIs we have available and which ones have yet to be implemented.

What’s a good way to track this, though?

Continue reading

Speaking at All Things WordPress North Atlanta

In a little less than a month, I’m going to be speaking at All Things WordPress North Atlanta. The meetup is run by Mickey Mellen of GreenMellen Media and who also helps co-organize WordCamp Atlanta.

All Things WordPress North Atlanta

I’ll be giving a talk called Work and WordPress: Pressware, Publishing, and Passion. Regardless of if you’re a user, implementer, or developer, there should be something for everyone.

Here are the details for the meetup.

Continue reading

Supporting More MIME Types in WordPress

Please see this comment for updated information about this filter.

If you have a project for a client or perhaps just for yourself, you may find that you need to upload a file in the WordPress back-end that is not supported by the core application.

Depending on the type of file that you want to introduce, you may need to add support for additional MIME types. Luckily, this is easy enough to do.

MIME Types in WordPress

No, not that type of mime.

But before looking at the code for how to do it, I think it’s important to understand exactly what we’re adding (otherwise, we run the risk of copying and pasting code and not knowing what it is or what it does other than it works).

Continue reading

How Do You Give Proper GPL Attribution?

GPL attribution is one of those tangential topics to a lot of the GPL discussion around WordPress (which I’m not interested in discussing here).

The GPL homepage for GPL attribution information.

Instead, what I’m trying to answer is this:

How do you give proper GPL attribution when using someone else’s work in your work?

Case in point: Let’s say someone is building a theme and wants to bundle some code you’ve written (and it’s available on GitHub) and is trying to attribute it properly to you?

First, this is something that someone was kind enough to ask me when working on a project of his own. Second, I think it’s a great question as it’s something we should all know how to answer since much of our work is likely using other third-party, open source libraries.

Continue reading

« Older posts Newer posts »

© 2025 Tom McFarlin

Theme by Anders NorenUp ↑