Update locale_helper.php

Adding back in deleted method.
This commit is contained in:
objecttothis authored and GitHub committed 2019-07-09 18:03:28 +04:00
1 parent 79e1ccc9a0
commit 9297e73b69
1 file changed
+5
+5
View File
@@ -561,6 +561,11 @@ function dateformat_bootstrap($php_format)
return strtr($php_format, $SYMBOLS_MATCHING);
}
function valid_date($date)
{
return preg_match('/^([0-9]{2,4})-([0-1][0-9])-([0-3][0-9])(?:( [0-2][0-9]):([0-5][0-9]):([0-5][0-9]))?$/', $date);
}
function valid_decimal($decimal)
{
return preg_match('/^(\d*\.)?\d+$/', $decimal);