module_iterate

Definition

module_iterate($function, $argument = '')
includes/module.inc, line 20

Description

Call a function repeatedly with each module in turn as an argument.

Code

<?php
function module_iterate($function, $argument = '') {
  foreach (module_list() as $name) {
    $function($name, $argument);
  }
}
?>
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.