You are here

function _login_destination_eval in Login Destination 7

Evaluate the code with forms context.

This function hides the calling function's scope from eval().

2 calls to _login_destination_eval()
_login_destination_evaluate_rule in ./login_destination.module
A helper function to evaluate destination path.
_login_destination_match_rule in ./login_destination.module
A helper function to determine whether redirection should happen.

File

./login_destination.module, line 436
Control where users are directed to, once they login

Code

function _login_destination_eval($code) {

  // We could use the php_eval(), but would not be able get array return value.
  // We always check for the existance of PHP Filter module for security.
  return eval('?>' . $code);
}