From e37b8be2410476618464256a7f6575a68071b660 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mart=C3=ADn=20Marrese?= Date: Wed, 11 Jun 2003 16:38:21 +0000 Subject: [PATCH 1/1] --- HTML/php/QuickForm/mdate.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/HTML/php/QuickForm/mdate.php b/HTML/php/QuickForm/mdate.php index 7f89537..d1b73ef 100644 --- a/HTML/php/QuickForm/mdate.php +++ b/HTML/php/QuickForm/mdate.php @@ -118,7 +118,12 @@ class HTML_QuickForm_mdate extends HTML_QuickForm_date */ function validate($valor, $nombre, $formato = '') { - return Validate::date($valor['Y'].'-'.$valor['d'].'-'.$valor['F'], array('format' => '%Y-%m-%d')); + if ($valor['Y'] != '--' && $valor['d'] != '--' && $valor['m'] != '--') { + return Validate::date($valor['Y'].'-'.$valor['d'].'-'.$valor['F'], array('format' => '%Y-%m-%d')); + } + else { + return false; + } } // end func validate } ?> -- 2.43.0