I'm R.J. and this is my blog, it's a smattering of thoughts around technology, programming, open source software, the Drupal framework, and managing insane clients & projects. Thoughts are my own, read at your own risk, always safe-for-work.

If you're on WAMP and using a CLI, here's how you automatically change PHP version in CLI when you change PHP version in WAMP

Over the weekend, I updated my local Drupal development environment to use WAMP instead of XAMPP, simply because WAMP lets you switch between versions of PHP. Unfortunately WAMP doesn't set the PATH to PHP so in your CLI you need to update PATH manually either in your environment variables (Windowz) or in .bashrc (Cygwin/*nix). I searched for a way to automate this and couldn't find anything so I wrote this small snippet to do it automatically.

The SysAdmin's Guide to Drupal 7

This post is written for SysAdmins, IT Directors, and CTOs who either manage a Drupal 7 site or are thinking of bringing a Drupal 7 site into their portfolio of technologies. My goal is to demystify Drupal and help you understand how it works, how to best manage it, and the various tools and techniques to help ensure a good experience with Drupal.

Creating a Field Formatter in Drupal to insert a block directly into a body field

In my personal blog I wanted to insert a block directly into a node's body field. The block contains an image and I want text to wrap around the image, therefore the block needs to be in the same div as the rest of the content. I could have hacked the tpl.php file and done something like an array_splice but I wanted something a little more elegant and Drupalish. A custom field formatter is exactly what I need, read more to see how I did it.

How to Interview a Drupal Developer

Over the last 5 years I've interviewed more than 100 candidates for Drupal/PHP developer positions in everything from 15 minute phone screens to 4 hour on-site interviews that include technical exercises. In 10 minutes I can gauge a candidate's skills and experience as a Drupal developer and if s/he is a good fit for a position. In this post I discuss my philosophy and methodology around hiring a *good* Drupal developer.

How to run Drush and other server side commands in a module

I am preparing to release my blog, rjtownsend.com, as a Drupal distribution in the next week or so, "when it's ready" as is commonly said in the Drupal community. One of the pieces I was working on this last weekend was a demo-mode module that uses Drush to generate content during install. Here's how I did it.

Using Drupal Services 3.x to create nodes from $_POST and $_FILES variables

SproutOnline.com has a variety of games and mobile apps that submit user-created data via POST to a URL and then email data to a gmail account. Not the most elegant way to do it but it's worked for years and they never had a problem. Last week something broke and we couldn't (quickly) find the cause. Instead of spending more time troubleshooting, I decided to create a resource in Services 3.x that would save each POST as a node. Read more to see how I did it.