function actions_get_all_actions

Retrieves all action instances from the database.

This function differs from the actions_list() function, which gathers actions by invoking hook_action_info(). The actions returned by this function and the actions returned by actions_list() are partially synchronized. Non-configurable actions from hook_action_info() implementations are put into the database when actions_synchronize() is called, which happens when admin/config/system/actions is visited. Configurable actions are not added to the database until they are configured in the user interface, in which case a database row is created for each configuration of each action.

Return value

Associative array keyed by numeric action ID. Each value is an associative array with keys 'callback', 'label', 'type' and 'configurable'.

3 calls to actions_get_all_actions()
trigger_assign_form in drupal/modules/trigger/
Returns the form for assigning an action to a trigger.
trigger_unassign in drupal/modules/trigger/
Form constructor for confirmation page for removal of an assigned action.
trigger_unassign_submit in drupal/modules/trigger/
Form submission handler for trigger_unassign().


drupal/includes/, line 190
This is the actions engine for executing stored actions.


function actions_get_all_actions() {
  $actions = db_query("SELECT aid, type, callback, parameters, label FROM {actions}")
    ->fetchAllAssoc('aid', PDO::FETCH_ASSOC);
  foreach ($actions as &$action) {
    $action['configurable'] = (bool) $action['parameters'];
  return $actions;