If the current date is near the end of the month, how can I set the calendar to auto show the next month?
To solve the issue of the calendar ever defaulting to this.
At the moment I have:
$(predecessor+"input.datePicker").datepicker({
minDate: 0,
changeMonth: true,
dateFormat: "dd/mm/yy",
firstDay: 1,
hideIfNoPrevNext: true,
showAnim: 'slideDown',
showOn: "both",
showOtherMonths: true,
showStatus: true,
maxDate: '-1d'
});
Datepicker has a defaultDate option that specifies which day starts out highlighted.
So, if you come up with your logic to determine when it needs to start on the next month, it should be pretty simple.
Use
beforeShow
Event to set the attributenumberOfMonths
Demo : http://jsfiddle.net/Z44PQ/1/, select 30 Nov and open again.