mirror of
https://github.com/smarty-php/smarty.git
synced 2025-10-17 14:35:19 +02:00
- bugfix replace modifier did not work in 3.0.7 on systems without multibyte support
- bugfix {$smarty.template} could return in 3.0.7 parent template name instead of child name when it needed to compile
This commit is contained in:
@@ -22,8 +22,10 @@
|
||||
*/
|
||||
function smarty_modifier_replace($string, $search, $replace)
|
||||
{
|
||||
require_once(SMARTY_PLUGINS_DIR . 'shared.mb_str_replace.php');
|
||||
return smarty_mb_str_replace($search, $replace, $string);
|
||||
if (function_exists('mb_split')) {
|
||||
require_once(SMARTY_PLUGINS_DIR . 'shared.mb_str_replace.php');
|
||||
return smarty_mb_str_replace($search, $replace, $string);
|
||||
}
|
||||
return str_replace($search, $replace, $string);
|
||||
}
|
||||
|
||||
?>
|
Reference in New Issue
Block a user