📌  相关文章
📜  如何在 jquery 中单击 datepicker 日期 - 无论代码示例

📅  最后修改于: 2022-03-11 14:59:07.940000             🧑  作者: Mango

代码示例1
$("#myDatePicker").datepicker({
    // The hidden field to receive the date
    altField: "#dateHidden",
    // The format you want
    altFormat: "yy-mm-dd",
    // The format the user actually sees
    dateFormat: "dd/mm/yy",
    onSelect: function (date) {
        // Your CSS changes, just in case you still need them
        $('a.ui-state-default').removeClass('ui-state-highlight');
        $(this).addClass('ui-state-highlight');
    }
});