mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-06 11:24:27 +02:00
fixed problem with math in certain LC_NUMERIC locales.
thanks to wiebren for providing problem+solution.
This commit is contained in:
@@ -58,7 +58,7 @@ function smarty_function_math($params, &$smarty)
|
|||||||
$smarty->trigger_error("math: parameter $key: is not numeric");
|
$smarty->trigger_error("math: parameter $key: is not numeric");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$equation = preg_replace("/\b$key\b/",$val, $equation);
|
$equation = preg_replace("/\b$key\b/", " \$params['$key'] ", $equation);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user