From d46948a88655dd7c7546447bf60c2ddb05eedb2e Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Sun, 8 Feb 2004 15:14:16 +0000 Subject: [PATCH] =?UTF-8?q?Ajout=20une=20option=20dans=20select=5Farray()?= =?UTF-8?q?=20pour=20afficher=20le=20code=20dans=20le=20libell=E9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/html.form.class.php | 66 +++++++++++++++++++++++++++----------- 1 file changed, 48 insertions(+), 18 deletions(-) diff --git a/htdocs/html.form.class.php b/htdocs/html.form.class.php index 9eb2d7c6f87..da9616da6da 100644 --- a/htdocs/html.form.class.php +++ b/htdocs/html.form.class.php @@ -101,9 +101,9 @@ class Form { } - Function select_date($set_time='', $prefix='re', $h = 0, $m = 0) + Function select_date($set_time='', $prefix='re', $h = 0, $m = 0, $empty=0) { - if (! $set_time) + if (! $set_time && !$empty) { $set_time = time(); } @@ -130,6 +130,15 @@ class Form { $smin = date("i", $set_time); print ''; + if ($empty) + { + print '\n"; + if ($key_libelle) + { + print ">[$key] $value\n"; + } + else + { + print ">$value\n"; + } } } else