jquery datepicker date format

jQuery UI DatePicker - Change Date Format

jQuery UI DatePicker - Change Date Format

$("#datepicker").datepicker().datepicker("setDate", "0");
$("#format").change(function () {
    var fromatVal = $(this).val();
    $('#formatVal').html(fromatVal);
    $("#datepicker").datepicker("option", "dateFormat", fromatVal);
});
DEMO
FormatDescriptionExample
dThe day of the month between 1 and 31."1" to "31"
ddThe day of the month with leading zero if required."01" to "31"
DAbbreviated day name. Date.CultureInfo.abbreviatedDayNames."Mon" to "Sun"
DDThe full day name. Date.CultureInfo.dayNames."Monday" to "Sunday"
mThe month of the year between 1-12."1" to "12"
mmThe month of the year with leading zero if required."01" to "12"
MAbbreviated month name. Date.CultureInfo.abbreviatedMonthNames."Jan" to "Dec"
MMThe full month name. Date.CultureInfo.monthNames."January" to "December"
yDisplays the year as a two-digit number."99" or "07"
yyDisplays the full four digit year."1999" or "2007"
jquery datepicker date format jquery datepicker date format Reviewed by Bhaumik Patel on 8:16 PM Rating: 5