You are here

function rules_token_list in Rules 6

Implementation of hook_token_list()

We expose some simple types to token so that our simple rules variables can also be used by others when doing token replacement.

File

rules/rules.module, line 1044
Rules engine module

Code

function rules_token_list($type = 'all') {
  $tokens = array();
  if ($type == 'string' || $type == 'all') {
    $tokens['string']['string'] = t("The sanitized string.");
    $tokens['string']['string-raw'] = t("The string, WARNING - raw user input");
  }
  if ($type == 'number' || $type == 'all') {
    $tokens['number']['number'] = t("The number.");
  }
  return $tokens;
}