How do I clear/reset the selected dates on the jQuery UI Datepicker calendar?

后端 未结 16 1656
感情败类
感情败类 2020-12-02 07:19

How do I reset the datepicker calendar values?.. The min and max date restrictions?

The problem is that when I clear the dates (by deleting the textbox values), th

16条回答
  •  悲哀的现实
    2020-12-02 07:55

    In Firefox it does job for me in form (programmatically), where datepicker control is disabled by default:

    $("#txtDat2").prop('disabled', false); //temporary enable controls
    $("#txtDat2").val("YYYY-MM-DD"); //reset date to dd.mm.yyyyy $("#txtDat2").prop('disabled', true); //back to default state

提交回复
热议问题