Community Documentation

Creating Notifications Plug-ins

Last updated March 19, 2009. Created by sagannotcarl on August 9, 2008.
Edited by sharplesa, udioron, Jose Reyero. Log in to edit this page.

To extend the Notifications framework to provide new event types or subscription types or UI elements, you create Notifications plug-ins. The Notifications package on drupal.org already includes several plug-ins that provide a set of flexible and configurable subscription types and UI widgets. (See notifications_content.module, included in the Notifications package.)

To build a plug-in, you implement the hooks provided by the Notifications and Messaging frameworks (usually hook_notifications() and hook_messaging()). By implementing these hooks, you won't have to handle low level features, like message templating and sending, queueing, database storage, etc...

NOTE: Contributed plug-ins are welcome. Or, if you are implementing the Notifications API from another module in a published package, let us know so we can link to it from the project main page. Other modules currently using this framework are Organic Groups and Mail to Web.

Comments

Notifications 4.x comes with Custom Subscriptions. If you are interested in learning how to extend this with your own modules, have a look at the tutorial here: http://groups.drupal.org/node/126059

Page status

No known problems

Log in to edit this page

About this page

Drupal version
Drupal 6.x
Audience
Developers and coders

Site Building Guide

Drupal’s online documentation is © 2000-2012 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution-ShareAlike 2.0. PHP code is distributed under the GNU General Public License.