Setting the maxDate option makes the textbox display the specified date which I believe should be the behavior of defaultDate?
$('#datepicker').datetimepicker({
format: 'MMMM D, YYYY',
maxDate: moment().subtract(18, 'y')
});
But if I remove the maxDate option, it behaves as normal - no date in the textbox.
I'm having the same issue.
ok solved. Set useCurrent:false
$('#datepicker').datetimepicker({
format: 'MMMM D, YYYY',
maxDate: moment().subtract(18, 'y'),
useCurrent: false
});
Most helpful comment
ok solved. Set useCurrent:false
$('#datepicker').datetimepicker({
format: 'MMMM D, YYYY',
maxDate: moment().subtract(18, 'y'),
useCurrent: false
});