I need to block Sundays in the Date & Time picker (new field since version 1.51.0). Is this possible?
The Java script below, which I use for the calender, is not working...
<script type="text/javascript">
function rsfp_onSelectDate(date, type, args, calendar)
{
var dates = args[0];
var date = dates[0];
var year = date[0], month = date[1], day = date[2];
var d = new Date(year, month-1, day);
if (d.getDay() == 0 || d.getDay() == 7) {
alert('Sorry, we are closed on Sunday...');
} else {
return true;
}
}
</script>