6 * @subpackage PluginsModifierCompiler
\r
10 * Smarty upper modifier plugin
\r
12 * Type: modifier<br>
\r
14 * Purpose: convert string to uppercase
\r
16 * @link http://smarty.php.net/manual/en/language.modifier.upper.php lower (Smarty online manual)
\r
18 * @param array $params parameters
\r
19 * @return string with compiled code
\r
21 function smarty_modifiercompiler_upper($params, $compiler)
\r
23 if (Smarty::$_MBSTRING) {
\r
24 return 'mb_strtoupper(' . $params[0] . ', \'' . addslashes(Smarty::$_CHARSET) . '\')' ;
\r
26 // no MBString fallback
\r
27 return 'strtoupper(' . $params[0] . ')';
\r