diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php
index 418f798dc34..c5fe199aa34 100644
--- a/htdocs/core/class/html.form.class.php
+++ b/htdocs/core/class/html.form.class.php
@@ -4843,7 +4843,9 @@ class Form
$more .= '
'.$input['label'].'
';
$more .= '
';
$addnowlink = (empty($input['datenow']) ? 0 : 1);
- $more .= $this->selectDate($input['value'], $input['name'], 0, 0, 0, '', 1, $addnowlink);
+ $h = $input['hours'] ?: 0;
+ $m = $input['minutes'] ?: 0;
+ $more .= $this->selectDate($input['value'], $input['name'], $h, $m, 0, '', 1, $addnowlink);
$more .= '
'."\n";
$formquestion[] = array('name'=>$input['name'].'day');
$formquestion[] = array('name'=>$input['name'].'month');