diff --git a/libs/plugins/function.math.php b/libs/plugins/function.math.php index 3e6d2c06..3230dec9 100644 --- a/libs/plugins/function.math.php +++ b/libs/plugins/function.math.php @@ -25,7 +25,7 @@ function smarty_function_math($params, &$smarty) } // match all vars in equation, make sure all are passed - preg_match_all("![a-zA-Z][a-zA-Z0-9]*!",$equation, $match); + preg_match_all("![a-zA-Z][a-zA-Z0-9_]*!",$equation, $match); $allowed_funcs = array('int','abs','ceil','cos','exp','floor','log','log10', 'max','min','pi','pow','rand','round','sin','sqrt','srand','tan');