X-Git-Url: https://git.llucax.com/mecon/meconlib.git/blobdiff_plain/12c3b7e967b107891284467e01c4e941223b29fe..46e1d55b1437c3eb73a9d877d9faae2979263639:/lib/MECON/HTML/QuickForm/mdate.php diff --git a/lib/MECON/HTML/QuickForm/mdate.php b/lib/MECON/HTML/QuickForm/mdate.php index 2697234..b1fb915 100644 --- a/lib/MECON/HTML/QuickForm/mdate.php +++ b/lib/MECON/HTML/QuickForm/mdate.php @@ -119,8 +119,8 @@ class HTML_QuickForm_mdate extends HTML_QuickForm_date function validate($valor, $nombre, $formato = '') { $str = sprintf ("%4d-%02d-%02d",$valor['Y'],$valor['F'],$valor['d']); - - if ($valor['Y'] != '--' && $valor['d'] != '--' && $valor['F'] != '--') { + + if (($valor['Y'] != '--' && $valor['d'] != '--' && $valor['F'] != '--') && ($valor['Y'] != '' && $valor['d'] != '' && $valor['F'] != '')) { return Validate::date($str, array('format' => '%Y-%m-%d')); } return true;