Drupal

Lessons from wresting with Drupal’s theme preprocessing functions.

 Drupal provides a lot of hooks that you can leverage to make it work exactly how you want.  I just finished tracing how some theme preprocessing functions were being executed, and realized that there are some subtle assumptions which I hadn’t understood earlier.  These are my notes about two specific preprocessing hooks and when they …

Lessons from wresting with Drupal’s theme preprocessing functions. Read More »

Tip: Disable Drupal performance settings

On development, testing, and staging site you normally don’t want Drupal’s caching, and javascript/css aggregation features enabled.  Drop the following into your sites settings.php file to override these settings.  // disable performance caching$conf[‘cache’] = 0;$conf[‘block_cache’] = 0;$conf[‘preprocess_css’] = 0;$conf[‘preprocess_js’] = 0;

Writing an intelligent hook_nodeapi function in Drupal

For Drupal module developers, the hook_nodeapi function affords a lot of flexibility for interacting with nodes at various operation.  If you just start pasting or writing code, you’ll quickly end up with a giant, messy switch statement.  But there is a simpel way to keep your code nicely organized.  First, lets take a look at …

Writing an intelligent hook_nodeapi function in Drupal Read More »