What are Loops in Drupal Rules?

| Drupal
Loops in Rules

Loops are potentially confusing, but they are a very useful feature in Drupal's Rules module.

Essentially a loop allows you to run an action over a list, rather than just a single item.

For example, in these videos, Robert has a list of multiple people who have edited a node. He creates an action to show the names of an editor, and then repeats that action for all the editors.

In programming terms, "Conditions" in Rules are similar to "if" statements and "Loops" are "for" loops that iterate over a list or an array.

These videos are part of our Drupal Advanced Rules Class.

Loops in Rules, Part 1

Loops in Rules, Part 2

About the author

Steve is the founder of OSTraining. Originally from the UK, he now lives in Sarasota in the USA. He was a teacher for many years before starting OSTraining. Steve wrote the best-selling Drupal and Joomla books.