From 691114595ca057a3d80aa9113e9e5c173aa63de3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20Mart=C3=ADn?= Date: Tue, 26 May 2009 17:17:43 +0200 Subject: [PATCH] Allow float numbers in numeric validations.(cherry picked from commit ab88493b28ed6d3b8158e2f5a455cf0aebd7eb7b) --- views/helpers/validation.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/helpers/validation.php b/views/helpers/validation.php index d027a98..28c10a9 100644 --- a/views/helpers/validation.php +++ b/views/helpers/validation.php @@ -205,7 +205,7 @@ function __convertRule($rule) { //(both +0123.45e6 and 0xFF are valid) then what is allowed in this regular expression. //99% of people using this validation probably want to restrict to just numbers in standard //decimal notation. Feel free to alter or delete. - return '/^[+-]?[0-9]+$/'; + return '/^[+-]?[0-9|.]+$/'; case 'range': case 'comparison': //Don't think there is a way to do this with a regular expressions,