If you are a Drupal site builder, defined as someone who installs and configures some of the thousands of contributed modules but doesn’t program custom modules, then at some point you run into a wall. Contributed modules will do a lot in Drupal, but they can’t often deal with your specific “if this occurs, then do this” kind of interactivity that makes a site more than static pages.
Of course in the Drupal tradition, “there is a module for that,” and that module is Rules. Rules lets you define actions that are to occur when specific conditions are met. For instance you can send an email to the administrator of the site when someone new registers on the site. While this kind of logic is relatively easy to implement as its own module, it requires programming skills. Instead Rules lets you define these kinds of reactions via Drupal’s web interface.
That’s all well and good if you want to take the time to figure Rules out. Like all flexible modules that can do a lot (Views comes to mind), Rules can be somewhat intimidating. I have to say the Rules documentation is some of the best for a contributed module and certainly should be reviewed. Sadly, like all Drupal documentation, since it is a Drupal book it takes a lot of clicking to navigate.
Drupal Rules How To is an alternative approach to learning rules. It was written by Robert Varkonyi who is has been developing in Drupal for six years. It’s a relatively short book, 75 pages in its PDF form. While I doubt anyone is going to read it like a novel, it wouldn’t take more than a couple of hours.
It’s organized as a series of how to’s, or recipes, on how accomplish various tasks. It’s odd the book title didn’t carry the cookbook moniker that other Packt books for Drupal have. Each task builds in complexity, starting with a very simple “Hello it’s Monday” message through rules that build lists of people and sequence through them sending emails on specific conditions
Each recipe is clearly laid out, with explanations followed by screen captures showing how the module should be configured to implement the recipe. It was easy to understand how the various steps fit together.
I think it would have been nice to have an overview of the Rules module and how it works. Actually that is one of the areas where the documentation on drupal.org is very well done.
Most chapters have a section called “there’s more” that offer possible expansions of the topic being discussed. I think it would have been more useful for inexperienced site builders if those expansions were turned into similarly complete recipes, I’m not sure that all site builders will be able to take the hints in those sections and use them without considerable trial and error.
The last third of the book is targets at Drupal developers, who write custom modules in PHP. While that part of the book does a decent job of documenting the API and various hooks that are available to allow a developer to extend Rules, it tends to only show the generic hook code, not a specific use of it. I would have liked to see an example that showed how a specific sample module would look.
When I was reading the book on my Kindle, I thought I had gotten a bad download. It just suddenly stops after the last recipe. Most books have some closing chapter, perhaps the author decided it was not needed. My first time through the Kindle version I thought it wasn’t optimized to let you use the table of content to jump to the section you want, but I realized I had to navigate the cursor into the table of content pages to notice that it does.
Bottom line is, if you are going to use Rules, you should buy and read Drupal Rules How To. It is inexpensive and will save you many times its cost in trying to figure out how to use this very flexible and powerful module.