Answer the question
In order to leave comments, you need to log in
Why is the next (2017) year not highlighted in the calendar?
not assigned by 2017, what to do?
http://jsfiddle.net/
var active_dates = ["15/11/2016", "16/01/2017"];
$("#datepicker").datepicker({
format: "dd/mm/yyyy",
todayHighlight: true,
maxViewMode: 0,
beforeShowMonth: 1,
beforeShowDay: function(date){
var d = date;
var curr_date = d.getDate();
var curr_month = d.getMonth() + 1; //Months are zero based
var curr_year = d.getFullYear() ;
var formattedDate = curr_date + "/" + curr_month + "/" + curr_year
if ($.inArray(formattedDate, active_dates) != -1){
return {
classes: 'booked '
};
}
return;
}
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question