Ever since I heard about the incredible performance gains possible by using HHVM instead of PHP’s native interpreter, I’ve dreamed of getting this working for some of my larger e-commerce client sites that struggle with performance. This past labor day, I moved to using ServerPilot.io (again, it’s awesome, get it. now) to manage my servers. It installs […]
Streamline Adding New Virtual Hosts to XAMPP With dnsmasq
I typically use MAMP Pro for local development, finding it to be a happy medium between the commitment and overhead of VVV and running my own LAMP stack. However, a friend recently pointed me to the comparative leanness of XAMPP, and the ability to use a wild card Virtual Host to simplify adding new sites. […]
How To Change Custom Post Type Archive Order
Post type archives are ordered by date, descending by default. This isn’t always desirable, especially for content whose chronology isn’t important. There are a few recommended methods for changing the order of custom post type archives, but the best technique I’ve found is this one: View the code on Gist. This example specifically changes the […]
How To Auto Fit Text To An Image With PHP and WordPress
Recently I took on a project where a client needed to generate an image on the fly, with a particular quote and they wanted to scale the text to fit the image on the fly. Which sounded perfectly daunting. But, I decided to try to tackle the problem anyway. It turns out there are plenty […]
Network Subsite Menu
Posted a small plugin to GitHub for setting up a global subsite menu in WordPress multisite. Basically, if you have a multisite WordPress install and you want to create a global menu with some or all of your subsites and show which subsite you’re on, this will help you build that menu. It doesn’t have […]
Loading An Ad Hoc Collection of Shopp Products
There are times when it’s convenient to load up an ad hoc collection of Shopp products. For example, today I was working on a site where I have relationships setup between Shopp products, and another post type called “Story Cards”. I set this relationship up using Posts 2 Posts, which is one of […]
Storing User Data with Shopp’s Session Management System
Storing user data and retrieving it can be a bit of a pain to manage, especially for small implementations where you only need to store a value or two. Fortunately, if you are writing a plugin for Shopp, you can stand on its giant shoulders and utilize their automatic session storage. This allows you to […]
Change WordPress Comment Notification Email Recipient, Conditionally
By default, WordPress notifies post authors of comments on their posts, and there are no settings that change this. If you’re like me, you may have found situations where this is less than ideal. For example, I’ve often found it advantageous to have all WordPress comment notifications go to a particular person, for a particular […]
MySQL, Stopwords, and You!
For the past few days, I’ve been looking into one of those problems that makes you feel literally crazy. A customer complained that when searching their store for the phrase “Keep Trying” no products showed up. Since this is a Shopp site, I looked at the index to verify the index had those words […]
Enabling Genesis SEO Metabox on Shopp Products
We recently released the shiny new Moore and Giles website, which is built on Genesis 2.0. This afternoon, we realized how nice it would be to have those Genesis SEO Metaboxes in the Shopp Product editor. This turned out to be delightfully simple, requiring only a few lines in functions.php: View the code on Gist. […]