Hi Jon,
I am trying to highlight days on the calendar. The highlighted days are from the view model(IEnumerable type). My code is as follows:
<script type="text/javascript">
var datesArray = new Array();
for (var item in Model) {
datesArray[datesArray.length] = "<%= item.PerformanceDate.Day %>";
}
$(document).ready(function() {
// Datepicker
$('.datepicker').datepicker({
inline: true,
beforeShowDay: function (date) {
var theday = date.getDate();
if ($.inArray(theday, datesArray) <0) return [true, ""];
return [true, "specialDate"];
}
});
});
Please let me know whats wrong with my code...
Thanks a Lot!! Anusha