Drupal tips, tricks, tutorials

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.

Advanced drupal 6.x hierarchical taxonomy list pages

A good quality taxonomy listing page can act as a really good sitemap. Good sitemap pages are great for internal linking effects that helps visitors browse your site, and coincidentally aids in SEO. Most (?all?) nodes will have taxonomy terms attached to them. Hence it's a pretty good start to aid someone to browse your site. The problem is the core taxonomy module doesn't make good quality listing of taxonomy terms. For instance it ignores the term hierarchy, it doesn't display links to child term pages, etc.

Feedback modules for Drupal

inspiration.jpgLooking at a colleague's website (organicJar.com) and was jealous over the Feedback button on the side of the page of that website. It's an AJAX'y button at the side, themed so it stands out well over any background content, and plops up a nice form letting visitors give feedback. See the image to the right. It's of course important to get feedback from your visitors, to engage visitors, and perhaps if they have a good experience on your site they'll return again in the future.

Review: Flash with Drupal

Review: Drupal 5 Views Recipes

It's curious that Drupal 5 Views Recipes is a brand new book, right?

Fix for when Drupal's cron.php redirects to a page rather than run cron.php

I've been having a headscratcher on a website for awhile and just found what the problem is. PROBLEM: When cron.php is requested, instead of running cron.php it redirects to some page on the site. This means the cron hooks aren't executed because instead some other page gets loaded. Drupal does a lot of maintenance stuff in the cron hooks, so it's bad news if they don't get executed.

Documentation of the normal setup for cron.php: http://drupal.org/cron .. I had done all that, and their troubleshooting section did not cover the problem I had.

Using MAMP for local Drupal development on a Mac

MAMP makes it pretty darn simple to do web development on a Mac. While Mac OS X comes bundled with Apache and PHP, MAMP bundles together the latest versions of both along with MySQL. It "installs a local server environment in a matter of seconds on your Mac OS X computer" and is completely self-contained. You can run MAMP alongside the Apache that's built-in to Mac OS X, you can remove MAMP at any time, etc. It's very convenient and flexible.

Repairing book navigation on a Drupal site

Maybe nobody else will find themselves in the situation that's in my hands right now. During the upgrade of this site from Drupal 5 to 6 the book navigation structure got screwed up. Drupal's book content is a tree structured set of pages which are loosely thought of as a "book". It's not really a book, but still the tree structure is a useful arrangement. I've published a lot of pages using the book structure and it was alarming that the structure got lost during the upgrade.

Pages