Error message

  • Deprecated function: Methods with the same name as their class will not be constructors in a future version of PHP; GeSHi has a deprecated constructor in require_once() (line 915 of /var/www/davidherron.com/sites/all/modules/libraries/libraries.module).
  • Notice: Trying to get property of non-object in block_block_view() (line 247 of /var/www/davidherron.com/modules/block/block.module).
  • Notice: Trying to get property of non-object in block_block_view() (line 247 of /var/www/davidherron.com/modules/block/block.module).
  • Notice: Trying to get property of non-object in block_block_view() (line 247 of /var/www/davidherron.com/modules/block/block.module).
  • Notice: Trying to get property of non-object in block_block_view() (line 247 of /var/www/davidherron.com/modules/block/block.module).

Drupal Tutorial

Configuring Drupal blocks when using the Domain Access module

Following on from my blog post the other day, Looking at (and a debugging tip) the Domain module for Drupal, I want to look at one of the gaps in the Domain Access module. Out of the box it does not modify the blocks configuration pages, meaning that out of the box all configured blocks show up for all domains. This is unlikely to be what you want, instead what's likely is to have different blocks for different domains.

A simple way to create a 'related posts' block using Views 2 in Drupal 6

Looking at the traffic data google Analytics collects on my web sites I see a high "bounce" rate which means many visitors leave right away. It means they come to the site, then look only at the one page, presumably to go elsewhere. I've been pondering what might be a good way to entice them to stay and look around. After all, my websites exist to instruct people, so the more pages they look at on my sites the more instruction I'm able to impart. Oh, and there's a higher chance they'll click on an ad or something.

Building a blog & podcast directory in Drupal using FeedAPI

Blog directories are simply a list of sites, characteristics of each site, and a listing of the recent blog posts on the site. They are very useful in helping people find blogs of interest. When a blog directory is focused on a specific topic it helps to build better awareness of that topic area. It's relatively easy to build a blog and podcast directory in Drupal using FeedAPI.

Cure for FAIL when using RedirectMatch with clean URL's on Drupal

I've had a problem with use of RedirectMatch on some of my sites which causes a FAIL in combination with Drupal's reliance on mod_rewrite to provide clean URL's. Over the years I've used different technologies to build sites and on occasion have converted a site built with static web pages into one driven with Drupal. This has meant a web of .htaccess files listing redirects for the old URL into a new URL. The goal is to help your readers continue to access the pages you wrote even when the location (URL) of the page changes.

Using views to publish both full and partial feeds in Drupal

There's a long standing debate over the content of RSS feeds. For the greatest convenience of your readers the full RSS feed is great, because they can read your articles in their feed aggregator. However as a publisher who needs to earn a living from my writing I only want to publish a teaser so that the reader will feel incentivized to visit my site. For me the feed is a lure to bring people to my site, and I cannot do justice to others' viewpiont.

Using Views 2 in Drupal 6 to replace the Tracker module

The core Tracker module is a convenient way to look at recent traffic on a Drupal site. It shows a list of recently posted (or modified) nodes along with useful data items for each node. However with Views 2 there is a more flexible way to implement the same functionality, without enabling another module.

The task is really pretty simple. Just download and enable the Views module, then in the Views configuration interface enable the Tracker view. Yup, coming bundled with the Views module is a predefined view which does every task the Tracker module does.

Using CCK's nodereference field for a kind of footnote

In two prior blog posts (see the references section below) I've discussed using a website content type to create resources lists. In this post I want to discuss another use, for a kind of footnoting system. You can see it in action below.

Creating a resources page in Drupal using a CCK content type

An earlier blog post (see references below) discussed a website node type that I frequently use. One purpose for the website node type is to build "resources" web pages. The "resources" page is an old practice on the Web where a site might host a resources page listing useful sites. These resources pages can be a gold mine of information for users, but I suppose it can be a pain to maintain if the page is a static page you have to remember to edit to add a new resource link.

Website nodes for Drupal as a key to building reference lists and footnoting

For several years I've used a CCK content type named 'Website'. The purpose has been to simply list links to websites for my reference and others benefit. The traffic on my sites shows that the website links (specifically the taxonomy pages listing the website nodes) are popular and in some cases the most popular part of the sites. In general "resources" pages are an old practice on the web, you'd see a "Resources" page on most sites that's a simple list of links to useful sites.

Pages