Highlight dates in specific range with jQuery's datepicker

后端 未结 7 1447
余生分开走
余生分开走 2020-11-27 19:06

I need to highlight the dates between a start date and an end date, which I should be able to specify. Can anyone help me?

7条回答
  •  执念已碎
    2020-11-27 19:54

    If you are using Keith Wood's datepick you can use the following example taken from here

    $(selector).datepick({onDate: highlightDays}); 
    
    function highlightDays(date) { 
        return {selectable: true, dateClass: 'highlight-custom', title: 'tooltip'}; 
    }
    

提交回复
热议问题