Code Posts

Local WordPress Development: From MAMP to Local by Flywheel


Years ago, when looking for a way to do local WordPress development, I eventually stumbled upon a pretty nifty tool called MAMP.  MAMP stands  for “Mac/Apache/MySQL/PHP”, and it’s the Macintosh equivalent of the well-known Linux-based LAMP stack. While you can configure MAMP by editing configuration files, I decided to upgrade to MAMP Pro, as it gives you an easier UI to use when managing some of your local websites. Despite MAMP ‘mostly working’, it has a number of really annoying downsides as well: MAMP Pro is paid software, but despite buying it multiple times, I don’t really feel like I’ve gotten good value with upgrades. Whenever I visit the website, it seems like there’s a new version that I have to upgrade to in order to even get a new PHP version etc. It’s very unstable: often it will seize up completely and you’ll have to force-quit it. This is […]

A ManageWP Review: Easy WordPress Site Management


I was recently attending WordCamp Europe near Amsterdam, and met Vladimir from ManageWP. I’ve heard lots about ManageWP over the last year or so, and even helped do an integration with WPtouch Pro to make it work with their system. But I’ve never actually sat down and spent any time with their system, and decided it was time to sign-up for an account, do a bit of exploring and write a basic ManageWP review to let people know what the service is all about. ManageWP is a service that basically helps you manage multiple WordPress websites, all from their own proprietary dashboard. As anyone who writes on more than one site knows, it can be a bit time consuming making sure all the plugins on each installation are up to date and that the system is in good health. ManageWP’s main value-add is helping to centralize the management of all […]

Configuring WordPress And Nginx


After my recent mention on Reddit last week, I decided to try and improve the responsiveness of my little DigitalOcean VPS even more than it already was. I was definitely happy that I was able to withstand almost 20,000 visitors in just a few hours, but thought I might be able to improve things further by switching from Apache to Nginx. I debated it a long time ago, but never made the plunge for a few different reasons. First, I typically used hosting services based on cPanel. From what I gather, cPanel doesn’t really work well with Nginx (or at all), so that was never really an option. And second, I could never quite figure out how to set up WordPress and Nginx properly so that they worked nicely together. It’s slightly more complicated because I often use W3 total cache, and it normally places its configuration into .htaccess for […]

Track Outbound Links On Your Website


I’ve been trying to track where exactly people go when they leave my website for a few pages recently, and wrote some code based on a few other examples on the Internet. Basically this bit of Javascript will force Google Analytics to log a special request so that you can see where the user went. It uses jQuery, so you have to make sure you have that included in your theme. Here’s some code that will let you track outbound links on your WordPress website. jQuery( ‘a’ ).on( ‘click’,function( e ) { var url = jQuery( this ).attr( ‘href’ ); var customName = jQuery( this ).attr( ‘data-link-name’ ); if ( !customName ) { customName = url; } if ( != ) { ga( ‘send’, ‘event’, ‘Outbound Link’, customName, document.title ); if (e.metaKey || e.ctrlKey) { var newtab = true; } if (!newtab) { e.preventDefault(); setTimeout(‘document.location = “‘ + […]

5 Ways To Speed Up Your WordPress Website


I’ve recently been optimizing a few different WordPress websites, and wanted to share with everyone some of the easy ways to speed up your WordPress website. Some of these tips are intended for server administrators and assume that you have root access to your server and/or cPanel/WHM (if you’re using cPanel). Other tips are intended for any WordPress website administrator. This article has 5 different tips for how to speed up your WordPress website. If you currently don’t have a WordPress website but are considering setting one up, here is information on how to setup a WordPress blog. Install a Caching Plugin Applies To: WordPress Administators Whenever a user views your website on a default WordPress installation, your webserver, which is often a program called Apache, will load all the PHP scripts for WordPress, compile them, execute the scripts, access all your content in the MySQL database, and ultimately send […]

WPtouch Pro 3.0: The Mobile Plugin For WordPress


Two days ago we finally pulled the veil off of WPtouch Pro 3.0, the mobile plugin for WordPress, which is a fairly substantial update to WPtouch Pro. Most of my family and friends know just how hard we’ve been working on it over the last few months, and especially these last few weeks. Last night we had a little party with a few employees and some company friends, and today most of us finally get to relax a little. The amount of effort we put into this launch we basically an order of magnitude larger than the one we did almost three years ago. As if it wasn’t hard enough launching just a new product, we also completely redid the website and support infrastructure. For the period of time the website was down on Thursday, we basically replaced our entire web infrastructure from top to bottom. The last launch I […]

Going Social: Tips and Tricks for Using WordPress with Social Media


Update: Here are the slides from the presentation – enjoy! I’m giving a talk in a few hours down at The Network Hub, and wanted to start a post here for some of the information. For those of you who can’t make it or are stuck on the waitlist, I’ll be talking about the following items: Creative Commons Licensing WordPress and Social Media Stats Plugin: Copyrighted Posts (Licensing Content) Plugin: Tweet, Like, Google +1 and Share (Sharing) Plugin: ShareThis (Sharing) Plugin: Sociable (Sharing) Plugin: Flickr RSS (Flickr) Plugin: MudSlideShow (Flickr/Picassa) Post From Flickr to WordPress (Flickr) Plugin: Viper’s Video Quicktags (Video) Disqus Commenting System Plugin: Add Link To Facebook (Facebook) Plugin: TweetMeme (Twitter) Plugin: WordTwit (Twitter) Plugin: WordTwit Pro (Twitter) Custom short URLs courtesy of YOURLs It’s a pretty demo-heavy presentation, so the slides will only be useful in that they’ll point you in the right direction. But the list […]

WordPress Trackbacks Explained


Since some of the current readers are new to blogging, I thought I’d spend a bit of time explaining the whole concept of trackbacks. Trackbacks are sort of an automated form of commenting so that when a blog entry is referenced by another one, this is reflected in the comments of the original blog entry. For example, let’s say I write a blog entry here, and Clay comes along like the bigshot he is and wants to link to it from his blog. There are two ways he can do it. First, he can link to the actual blog entry itself, which at first seems like a good thing to do if you’re Clay. Unfortunately, if he does that, the only person who will know about that link is Clay and the other three people who read his blog. Trackbacks Explained The right way to do it (at least in […]