disable past dates on datepicker

前端 未结 22 1315
梦毁少年i
梦毁少年i 2020-11-29 06:03

How to disable past dates from the current date on a datetimepicker? I tried few posts for similar question but was unable to achieve it, Below is what I tried



        
22条回答
  •  天涯浪人
    2020-11-29 06:42

    this works for me,

    $(function() { $('.datepicker').datepicker({ startDate: '-0m', autoclose: true }); });

提交回复
热议问题