Minifycode 2020-02-22 Viewed 1.3K times Jquery

In this article, you will learn what is jQuery Datepicker

In this post jquery that attaches a popup calendar to your input fields or shows an inline calendar for selecting individual date range date.

<input id="defaultPopup" size="12">
$('.disablePicker').click(function() { 
    var enable = $(this).text() === 'Enable'; 
    $(this).text(enable ? 'Disable' : 'Enable'). 
        siblings('.is-datepick').datepick(enable ? 'enable' : 'disable'); 

set defaults

$.datepick.setDefaults({pickerClass: 'my-picker'});

Add the jQuery library in the head section of your page

<script type="text/javascript" src=""></script>

Date format

$(selector).datepick({dateFormat: 'yyyy-mm-dd'});

Programatically, use the getDate method:

var date = $(selector).datepick('getDate');


jQuery Datepicker
minify code