You are here

function _rules_action_drupal_goto_handler in Rules 6

Page template preprocess handler for the drupal goto action.

See also

rules_theme_registry_alter().

Related topics

1 string reference to '_rules_action_drupal_goto_handler'
rules_theme_registry_alter in rules/modules/rules.events.inc
Implementation of hook_theme_registry_alter().

File

rules/modules/system.rules.inc, line 204
rules integration for the system module

Code

function _rules_action_drupal_goto_handler($variables) {
  if (isset($GLOBALS['_rules_action_drupal_goto_do'])) {
    unset($GLOBALS['_rules_action_drupal_goto_do']);

    // We have already set $_REQUEST['destination'] which drupal_goto() is going to respect.
    drupal_goto('');
  }
}