function RulesI18nStringEvaluator::help

Overrides RulesDataInputEvaluator::help().

Parameters

array $variables: An array of info about available variables.

array $param_info: (optional) An array of information about the handled parameter value. For backward compatibility, this parameter is not required.

Return value

array A renderable array.

Overrides RulesDataInputEvaluator::help

File

rules_i18n/rules_i18n.rules.inc, line 192

Class

RulesI18nStringEvaluator
A class implementing a rules input evaluator processing tokens.

Code

public static function help($var_info, $param_info = array()) {
  if (!empty($param_info['translatable'])) {
    if (!empty($param_info['custom translation language'])) {
      $text = t('Translations can be provided at the %translate tab. The argument value is translated to the configured language.', array(
        '%translate' => t('Translate'),
      ));
    }
    else {
      $text = t('Translations can be provided at the %translate tab. The argument value is translated to the current interface language.', array(
        '%translate' => t('Translate'),
      ));
    }
    $render = array(
      '#theme' => 'rules_settings_help',
      '#text' => $text,
      '#heading' => t('Translation'),
    );
    return $render;
  }
}