function rules_input_evaluator_callback_prepare in Rules 6
Prepares the evalution.
It is used to determine whether the input evaluator has been used. If so arbitrary data may be passed to application callback - e.g. a list of used variables. It should be placed into the file MODULENAME.rules.inc.
Parameters
$string: The string to evaluate later on.
$variables: An array of info about available variables.
Return value
Arbitrary data, which is passed to the evaluator on evaluation. If NULL is returned the input evaluator will be skipped later.
See also
hook_rules_evaluator(), rules_input_evaluator_php_prepare().
Related topics
File
- rules/
rules.api.php, line 496 - This file contains no working PHP code; it exists to provide additional documentation for doxygen as well as to document hooks in the standard Drupal manner.
Code
function rules_input_evaluator_callback_prepare($string, $variables) {
// Scan the string for evaluator usage and
return TRUE;
}