WordPress Week

I host all my WordPress clients at DreamHost. This offers me a number of advantages. First, there are two platforms available to me: shared hosting and my own VPS. Shared hosting works fine for low-volume websites that are mostly static pages. If I front them with caching from CloudFlare (or something similar) then no-one can tell the difference. For those clients with eCommerce sites or high traffic, then I host them on my VPS which has plenty of headroom to spare.

Another advantage of DreamHost is that they periodically scan client sites for malware. This costs nothing more and is to their advantage. Sites hosting scams ruins reputations and often consume resources that could be better used to serve legitimate operations. And if things go really bad, I can restore a website via the admin panel from a old backup and/or purchase their website repair service at a reasonable rate.

One downside, though, is that occasionally you get a notification from DreamHost that they are going to be discontinuing support for something. Recently, it was for PHP 7. All websites on shared hosting must be upgraded to PHP 8. This made sense since support for PHP 7 had ended a while ago. But going through all my client websites and confirming that they would work with PHP 8 was an unexpected fire drill.

Fortunately their technical support people told me about a tool that I hadn’t heard about. It was the command line tool WP-CLI. Turns out that this tool will let me log into the root directory of each of my client WordPress websites and get a report on which plug-ins and themes are PHP 8 compatible and which are not.

It took me a week but I was able to go through all my client websites on shared hosting and identify all of the problem areas. Some were plug-ins that already disabled. So that was easy. Some were themes could be updated with newer releases. Some I had to fix myself: there were a lot of instances of array references with curly braces ({}) instead of square brackets ([]) that, once repaired, worked fine on PHP 8.

In the end, I was able to upgrade all the websites a day ahead of the deadline. Now all that’s left is a few of the troublesome sites on the VPS that have themes that aren’t so easily updated by hand. Luckily I haven’t been told that I need to update those yet. But you know it’s coming eventually. Such is the joy of providing managed hosting!

Leave a Comment

Scroll to Top
Skip to content