There are similar questions in stack overflow , but i didnt find answer for me .
Here is HTML code,
<div id="datepicker"></div>
JS :
$("#datepicker").datepicker();
on change the next , previous button events, i used ,datepicker option
onChangeMonthYear:function(year, month, widget){
$.ajax( "/getdates",{year:year,month:month},function( data ) {
// data = ['10/15/2014','11/15/2014']
});
}
I want to enable the those dates which i got in data
i tried beforeShowDay
which works onload , but i dont know how to enable/disable the calendar on every ajax request during change the month/year