I am using this tutorial, but I have it slightly modified some fields for my needs, nothing special, just :
$('.txtDate').datepicker({
changeMonth: true,
changeYear: true,
showOn: 'focus',
showAnim: "fadeIn",
dateFormat: 'dd/mm/yy',
autoSize: true,
yearRange: '1900:+0',
onSelect: function (dateString, txtDate) {
ValidateDOB(dateString, txtDate.id);
}
});
these are html inputs (I have multiple of them):
<label class="mr-3" for="c1_dob">Birthday <span>*</span></label>
<input class="txtDate" type="text" id="c1_dob" autocomplete="off" name="c1_dob" onkeydown="return false;" required/>
the rpoblem is, that sometimes the date is saved to DB as 1970-01-01. At which input will that happen is also not clear. Pure random. can some1 point me, why does it happen? If you need to see more code, don't hesitate to ask.