Drupal 5

Spring Cleaning Your Drupal Site

Submitted by mgifford on

Many people celebrate spring by doing an intensive cleaning of their house, getting rid of stuff that isn't needed any more, putting away the winter clothes/jackets and cleaning in those places that you don't get to on a daily basis.  It occurred to me that most CMS admins should take on a practice like this at least every year when I started looking at broken links. 

Checking for Bad Links

Now the dead links are inevitable in any website that's up for any length of time.  I was looking for a way to provide a list of broken links when I came upon the Dead Link Checker site.  Just read that if the spider finds a link towards their site, the bot will crawl deeper into your website, cool. This trolls through a site for up to 45 minutes collecting and looking for broken links.  Quite a useful service, and like so many on the web it is free.  There are other ways to check an entire site's links, but generally most free services only allow you to check by the page.  That's useful for any site and is pretty painless (other than tracking down and deciding what to do with the old links). 

Using SimpleTest in Drupal 5

Submitted by Pawel on

I have been writing a unit test for the connect module using the simpleTest module. The following is a discussion of my experiences. This article from Lullabot is what I mainly used as a reference. Note that if you are following this article be sure to read the comments at the bottom. Especially that hook_simpletest is not required.

Installing SimpleTest

In Drupal 5 simpleTest uses a PHP library for its testing. In later versions of Drupal this library is not used. Once you have finished downloading the simpleTest module read the INSTALL.txt file. The only extra step to configuring this module is to download the simpleTest PHP library and placing it in the ...all/modules/simpletest/simpletest directory.

Creating custom CCK widgets

Submitted by ethan on

CCK is an excellent way of customizing node types without so much as a line of custom PHP. However, if you wish the node to be part of some sort of dynamic process where nodes interact or are part of a process, you'll probably need to delve into widgets and fields a little bit deeper.

In this case, we wanted to link a node describing a petition with node describing a petitioner (name, address, email, etc.)- and we wanted to take advantage of CCK. We have a parent-child relationship, where at least one of the nodes must have a field pointing to it's counterpart. Fortunately, the nodereference field already exists, so all we need to do is supply it with data. We're going to do just that by supplying it with the last argument of the referring URL.

Subscribe to Drupal 5