O'Reilly logo

Drupal® 7 Bible by Brice Dunwoodie, Ric Shreves

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 9. Using Actions and Triggers

IN THIS CHAPTER

  • The default simple actions

  • Adding an advanced action

  • Assigning triggers to actions

Actions and triggers are native Drupal functionalities that work together allowing you to define sets of automatic operations that take place following certain system events. For example, you may want to send an e-mail to the author of an article every time someone comments on it, thus ensuring that he or she can respond to the comment in a timely fashion.

In this chapter, I introduce the default set of Drupal actions, how to go further by creating your own Advanced actions, and finally how you go about connecting system events, called triggers, to defined actions.

Note

Both actions and triggers are core Drupal functionalities. Actions are considered part of the system and cannot be disabled. On the other hand, you will find that triggers, despite being a part of the system core, are disabled by default. You must enable the core Trigger module before you can work with triggers.

The Default Simple Actions

When you set up a standard Drupal installation, you find a number of simple system actions already defined. Navigate to the Actions screen found in the System section of the admin Configuration area, and you see a list of actions as shown in Figure 9.1.

The default Actions screen shows the list of simple actions.

Figure 9-1. The default Actions screen shows the list of simple actions.

The default set of simple actions ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required