Reputation: 6952
So I have a date picker and I want to get back a max date. I have somthing like this
$( "#datepicker" ).datepicker({ minDate: -20, maxDate: "+1M +15D" });
how can I get the maxDate value formatted in MM/DD/YYYY?
Thanks for your help guys
Upvotes: 4
Views: 9517
Reputation: 6127
$('#datepicker').datepicker( "option", "dateFormat", 'mm/dd/yyyy' );
And then specify your maxdate
in mm/dd/yyyy.
Upvotes: 6