diff --git a/htdocs/compta/sociales/card.php b/htdocs/compta/sociales/card.php
index bcfa574d696..79a998a3278 100644
--- a/htdocs/compta/sociales/card.php
+++ b/htdocs/compta/sociales/card.php
@@ -429,7 +429,7 @@ if ($id > 0) {
if (!empty($conf->global->TAX_ADD_CLONE_FOR_NEXT_MONTH_CHECKBOX)) {
$formquestion[] = array('type' => 'checkbox', 'name' => 'clone_for_next_month', 'label' => $langs->trans("CloneTaxForNextMonth"), 'value' => 1);
} else {
- $formquestion[] = array('type' => 'date', 'name' => 'clone_date_ech', 'label' => $langs->trans("Date"), 'value' => -1);
+ $formquestion[] = array('type' => 'date', 'datenow'=>1, 'name' => 'clone_date_ech', 'label' => $langs->trans("Date"), 'value' => -1);
$formquestion[] = array('type' => 'date', 'name' => 'clone_period', 'label' => $langs->trans("PeriodEndDate"), 'value' => -1);
}
@@ -546,7 +546,7 @@ if ($id > 0) {
// Date
if ($action == 'edit') {
print '
| '.$langs->trans("Date")." | ";
- print $form->selectDate($object->date_ech, 'ech', 0, 0, 0, 'charge', 1);
+ print $form->selectDate($object->date_ech, 'ech', 0, 0, 0, 'charge', 1, 1);
print " |
";
} else {
print "| ".$langs->trans("Date")." | ".dol_print_date($object->date_ech, 'day')." |
";
diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php
index 4390b233831..48774c0fe66 100644
--- a/htdocs/core/class/html.form.class.php
+++ b/htdocs/core/class/html.form.class.php
@@ -4803,7 +4803,8 @@ class Form
} elseif ($input['type'] == 'date') {
$more .= ''.$input['label'].'
';
$more .= '
';
- $more .= $this->selectDate($input['value'], $input['name'], 0, 0, 0, '', 1, 0);
+ $addnowlink = (empty($input['datenow']) ? 0 : 1);
+ $more .= $this->selectDate($input['value'], $input['name'], 0, 0, 0, '', 1, $addnowlink);
$more .= '
'."\n";
$formquestion[] = array('name'=>$input['name'].'day');
$formquestion[] = array('name'=>$input['name'].'month');