noalyss-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Noalyss-commit] [noalyss] 09/19: zero is considered as empty value


From: Dany De Bontridder
Subject: [Noalyss-commit] [noalyss] 09/19: zero is considered as empty value
Date: Thu, 12 Dec 2019 15:49:05 -0500 (EST)

sparkyx pushed a commit to tag rel7200
in repository noalyss.

commit 867b757a7072682c85aebcead56aff42bb7a3fdd
Author: Dany De Bontridder <address@hidden>
Date:   Wed Dec 4 20:04:14 2019 +0100

    zero is considered as empty value
---
 include/lib/http_input.class.php | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/lib/http_input.class.php b/include/lib/http_input.class.php
index fab33d2..ac3b1d9 100644
--- a/include/lib/http_input.class.php
+++ b/include/lib/http_input.class.php
@@ -82,7 +82,7 @@ class HttpInput
             // Check if number
             else if ($p_type=="number")
             {
-                if (empty($this->array[$p_name]))
+                if (trim($this->array[$p_name]) == "")
                 {
                     $this->array[$p_name]=$this->empty;
                 }
@@ -97,7 +97,7 @@ class HttpInput
             // Check if date dd.mm.yyyy
             else if ($p_type=="date")
             {
-                if (empty($this->array[$p_name]))
+                if (trim($this->array[$p_name]) == "" )
                 {
                     $this->array[$p_name]=$this->empty;
                 }
@@ -110,7 +110,7 @@ class HttpInput
             }
             else if ($p_type=="array")
             {
-                if (empty($this->array[$p_name]))
+                 if (trim($this->array[$p_name]) == "" )
                 {
                     $this->array[$p_name]=$this->empty;
                 }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]