Drupal Blog

Drupal 6: user_badges_taxonomy Module
Last edited on: 15/01/2012 - 22:23

The motivation for this module came from a shortcoming of the functionality of the user_badges module and the thread http://drupal.org/node/1144296 questioning the usage of the vocabulary feature in the user_badges module. It appears that this enables the assignment of badges to users for arbitrary achievements. For instance, a client of mine is a political campaigning organisation and it would be cool to assign badges to those activists who attend campaigns.

»   Read more
Drupal 6: Programmatically Remove Required Field Property from Form
Last edited on: 19/11/2011 - 12:06

Suppose you are coding a form in Drupal 6 and you have a mandatory (required) field. However, this required field is only mandatory dependent upon the value in another field. This can happen quite often, and I encountered it at a client site the other day. We had a postcode field that was mandatory only if the country in a selection box was set to 'United Kingdom'. Any other country meant that the postcode field was not required.

»   Read more
Drupal 6: Programmatically Create Panels and Nodes in Panels
Last edited on: 28/07/2011 - 13:26

This tutorial provides the wherewithal to create a new node and insert that node in the top pane on a programmatically created Panel. Looking around the net I was surprised that nobody has done this before. The context for my requirements comes from a not-for-profit client of mine - they wanted to be able to create a new type of charitable donation dependent upon a campaign's remit (this would be the node) and then to place that campaign information (node) in the top pane of the panel.

»   Read more
Drupal 6 Checkboxes and default_value
Last edited on: 29/04/2011 - 08:57

The Drupal Forms API comes with some powerful features, including checkboxes which allows a bunch of checkbox options to be grouped together. Included in this functionality is the ability to set default values, i.e. set your chosen boxes to be on.

However, it is not immediately obvious how to programmatically set the default values using the '#default_value' key. The key expects an array, so I tried the usual contenders such as an array of 0s, 1s, 'on', FALSE, TRUE etc etc and just couldn't get it to work correctly.

»   Read more
Drupal 6 White Screen of Death on Top Level Landing Page
Last edited on: 06/02/2011 - 13:04

I have a number of Drupal sites on the Internet; more than I can possibly check on a daily basis, what with work commitments and all. I pointed my web browser at one of the more infrequently visited sites the other day and was confronted with the White Screen of Death. Disaster! What on Earth can cause that? And how long had the site been down? A quick check of the log gave no evidence of anything amiss, and the integrity of the database looked ok with a cursory glance.

»   Read more
Drupal Bookcat Module
Last edited on: 14/10/2010 - 08:18

Welcome to the home page of the Drupal Bookcat module. Bookcat is a read-only port of the Explorer output of FNProgramvare's Bookcat book collector's database Windows product. It must be stressed that my module in no way replaces FNPRG's product of the same name - it merely extends its usefulness by making your Bookcat databases available to a wider user-base on the Drupal platform.

»   Read more
Drupal Magcat Module
Last edited on: 07/10/2010 - 08:21

Welcome to the home page of the Magcat Drupal 6 Module - an add-on to my Bookcat Drupal 6 Module. Magcat is aimed primarily at those with magazine collections; out of the box, FNProgramvare's Bookcat does not lend itself to magazine collections, but by using the available custom fields, and by creating some new template pages in my Magcat module, it is a perfect fit! Laughing out loud

»   Read more
Drupal 6 SMS Framework: Esendex PHP5 SOAP Gateway
Last edited on: 10/05/2010 - 13:50

Drupal 6 SMS Framework enables the sending of SMS from a Drupal 6 website, through a suitable bureau service. The 'glue' between the SMS Framework module and the chosen SMS bureau is called a 'gateway'. Each bureau needs the development of a dedicated gateway, and currently there are few available. In reality, the only gateways for Drupal 6 are Clickatell and a generic email facility.

»   Read more
Drupal 6 dCaldav Caldav/Webdav Client Module
Last edited on: 23/04/2010 - 18:56

CaldavdCaldavThe sporting fixtures listed on this website under the "Sporting Fixtures" menu item are created automatically using my own Drupal 6 dCaldav module.

»   Read more
Drupal 6 Bulk Save of Taxonomy Terms with Perl
Last edited on: 23/04/2010 - 09:59

You may be faced with the prospect of performing a batch save of taxonomy terms on your Drupal 6 installation. Using the normal interface, despite being clean and efficient, it could be an onerous task of many mouse clicks and wandering concentration resulting in errors. I was faced with such a situation so decided to quickly develop my own utility to perform a bulk save on my behalf. I decided upon Perl as the language to code in because I did not want the development time associated with user interfaces - this utility is for command line aficionados.

»   Read more