Drupal Module Development Training Course


Drupal Module Development

In this 2-day training course participants will learn how to get custom functionality using Drupal’s hook system, as well as how to extend or alter contributed module functionality. Participants in this course will have used CCK, Views and Panels to create websites but have never built their own module. We will start with writing a simple module and move to writing a complex module, step by step, which uses Forms API, Schema API, all of the top ten Drupal hooks, creates custom database tables.


2 days

Course Objectives

By the completion of this course, the participants should be able to:

  • Get custom functionality out of Drupal
  • Extend built-in Drupal modules with the custom code
  • Learn about Menus and Permissions systems
  • Learn about Drupal Form system and variables
  • Learn to use Database Abstraction Layer in Drupal
  • Learn about SimpleTest – Drupal’s custom testing framework
  • Know best practices of developing Drupal modules


IT professionals who want to broaden their Drupal skills and learn how to extend and build new Drupal modules


Knowledge of PHP and basic understanding of Drupal is required to get the most out of this class. If you don’t have PHP experience, we recommend taking this course first:


Session 1: Extending Drupal with custom code

  • Drupal as a framework
  • Your first module: The Red Button
  • Efficient coding
  • Introducing MailFish

Session 2: Menus and permissions

  • Menu System: Defining menu callbacks
  • The Permissions System
  • Menu Callback Files (.admin.inc, .pages.inc)

Session 3: Form API (Part 1)

  • Form System: Drupal Form API and Form Creation
  • Drupal Variables
  • Challenge: Using drupal_get_form as a callback

Session 4: Install files

Session 5: Form API (Part 2)

  • Form Validation and Submission

Session 6: Exploring modules

Session 7: Node operations

Session 8: Database system

  • Database Abstraction Layer

Session 9: Block system and theme system

  • Theming the MailFish Subscription Block

Session 10: Reporting results

Session 11: SimpleTest