Software Engineering in WordPress, PHP, and Backend Development

Tag: WordPress (Page 41 of 219)

Articles, tips, and resources for WordPress-based development.

A Short-Guide to Changing Valet’s Top-Level Domain

For years, developers have used the dev top-level domain as a way to work with local development versions of their projects.

But Google changed all of that last year.

If you’re interested in reading a bit more into this, check out the post by Justin from WebDevStudios does a good job of going into some of the details (as does this post via Daryl Koopersmith – previously working on WordPress, now working at Medium).

But for this post, I’m trying to keep it short and pragmatic. So, the former is this:

If you’re using HTTPS and a dev domain on your local machine, it’s likely going to stop working. Yes, you can add an exception with some browsers, but not all.

Changing Valet's Top-Level Domain: Firefox Security Exception

If you’ve read this blog for any particular length of time, then you know that I’m a fan of using Valet as part of my local development environment. Part of doing that means that I also secure the local sites to simulate, as much as possible, but staging and production are going to be like.

By default, Valet uses dev as it’s top-level domain, so how do we change that? Luckily, it’s pretty easy.

Continue reading

Customizing the WordPress Administration Menu (For User Experience)

For some projects, there are going to be times where there’s not a lot of new stuff to explore, you know? You get the requirements, you know how to solve the problems, and then you move forward with building the solution.

Then other projects that come your way and though you may not know how to do them at the beginning of the project, you know you’ll be able to do so programmatically because if it’s written in code, it’s going to be possible.

And the more you become familiar with a given set of tools or platform (like WordPress), then the more likely you are to “think in terms” of that platform, right?

Perhaps one case in point is working with the administration menu in WordPress. When it comes to projects that others build, I don’t know if they aim to create as positive experience on the front-end as the back-end, but I think it’s import to consider the entire application as an experience for the user.

Customizing the WordPress Administration Menu

And that’s why when it comes to little things – even the menu, for example – that it’s important. But what do I mean by that?

Continue reading

How To Remove Special Characters from Permalinks

Whenever you’re working with WordPress and third-party APIs, there’s always a chance that you’re going to run into issues where the third-party API is not prepared to handle certain characters that exist in a permalink.

Depending on one’s permalink settings, though, this may or may not be an issue. For example, you may have your permalinks set to something like ?p=123 for each post. In that case, it’s not much of an issue.

But if you’re using “pretty permalinks” and your permalink includes something like a trademark symbol or a copyright symbol, then it may cause problems whenever you’re communicating with said third-party API.

Continue reading

Gracefully Handle PHP Version Support in WordPress

As long as I’ve been working with WordPress, the conversation (and I do use this term loosely) around what versions of PHP it should or shouldn’t support has been ongoing.

  • The short of it is that some see it as an application as large and popular as WordPress that powers so much of the CMS-based websites should be able to use its clout to foster more innovative solutions.
  • Others see that people don’t often upgrade, are on budget hosts, or simply do not care (let alone bother to know) what version of PHP they are running.

These two points could yield a post and comments for days, but I’m not interested in that. Because my team and I are the business of building custom solutions for others, we have the flexibility of taking stock of where the users host their site or application, deploying it, and leveraging features of PHP offered by their hosts.

There are, however, times where I’ve encountered some people running versions of PHP as low as 5.3.

So what then?

Continue reading

Developing Plugins and Themes Against WordPress Trunk

When developing plugins or themes for WordPress, one of the strategies that I often recommend is doing so against trunk (or the current snapshot of the code) of WordPress.

For those who are more experienced developers, you’re already on the up-and-up on the lingo and the caveats that come with doing this. But if you’re someone who is looking for ways to better their development practices, then perhaps this will help.

Remember that because WordPress is open source software, you can view the source code on the web at anytime.

Developing Against WordPress Trunk: trunk

Not only that, but you can download it to your local computer and work with it, as well. This will require certain pieces of software, and I’ll get into that momentarily; however, the ultimate purpose of this post is to talk about:

  • how to work with the current snapshot of code with WordPress,
  • how and why it may be beneficial to use this codebase when working on projects for others.

As stated above, there are caveats for doing this, and sometimes it’s a good idea to use the latest stable version of the codebase. And I’ll address that later in the article, as well.

Continue reading

« Older posts Newer posts »

© 2025 Tom McFarlin

Theme by Anders NorenUp ↑