1

I want to disable/remove Sunday from js calendar and its related dates also.

Can somebody tell me how can I achieve this?

I search from google but all says to hide weekend, I just want to hide only Sunday and its related dates.

enter image description here

Thanks in advanced.

  • jsfiddle.net/zXFGN – Aditya Shah Oct 24 '18 at 13:05
  • $( "#noSunday" ).datepicker({ beforeShowDay: noSunday }); – Aditya Shah Oct 24 '18 at 13:05
  • function noSunday(date){ var day = date.getDay(); return [(day > 0), '']; }; – Aditya Shah Oct 24 '18 at 13:06
  • yeah! it works please post an answer – Hitesh Oct 24 '18 at 13:24
2
$( "#noSunday" ).datepicker({ 
        beforeShowDay: noSunday
});

function noSunday(date){ 
     var day = date.getDay(); 
     return [(day > 0), '']; 
}; 
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.