6 * @subpackage PluginsModifierCompiler
10 * Smarty upper modifier plugin
13 * Purpose: convert string to uppercase
15 * @link http://smarty.php.net/manual/en/language.modifier.upper.php lower (Smarty online manual)
18 * @param array $params parameters
20 * @return string with compiled code
22 function smarty_modifiercompiler_upper($params)
24 if (Smarty::$_MBSTRING) {
25 return 'mb_strtoupper(' . $params[0] . ', \'' . addslashes(Smarty::$_CHARSET) . '\')';
27 // no MBString fallback
28 return 'strtoupper(' . $params[0] . ')';