Questions tagged [jquery-ui-datepicker]

A datepicker widget from jQuery-ui which allows the user to select a date from a popup or inline calendar

The Datepicker is a highly configurable plugin that adds datepicker functionality to your pages. You can customize the date format, language, restrict the selectable date ranges, add buttons and other navigation options easily. The style is fully customizable.

More information can be found on the jQuery UI website and in the API Documentation. For localization visit the GitHub repository.


Example:

$("#selector").datepicker({
  // Options
});

Options:

  • altField
  • altFormat
  • appendText
  • autoSize
  • beforeShow
  • beforeShowDay
  • buttonImage
  • buttonImageOnly
  • buttonText
  • calculateWeek
  • changeMonth
  • changeYear
  • closeText
  • constrainInput
  • currentText
  • dateFormat
  • dayNames
  • dayNamesMin
  • dayNamesShort
  • defaultDate
  • duration
  • firstDay
  • gotoCurrent
  • hideIfNoPrevNext
  • isRTL
  • maxDate
  • minDate
  • monthNames
  • monthNamesShort
  • navigationAsDateFormat
  • nextText
  • numberOfMonths
  • onChangeMonthYear
  • onClose
  • onSelect
  • prevText
  • selectOtherMonths
  • shortYearCutoff
  • showAnim
  • showButtonPanel
  • showCurrentAtPos
  • showMonthAfterYear
  • showOn
  • showOptions
  • showOtherMonths
  • showWeek
  • stepMonths
  • weekHeader
  • yearRange
  • yearSuffix

References

Related Tags

2969 questions
70
votes
8 answers

jQuery Datepicker localization

I need a french calendar and I can't understand the problem. I guess I'm not using the regional options like it should be. But... Here is my code : $(function() { $('#Date').datepicker({ showMonthAfterYear: false, showOn: 'both', …
69
votes
5 answers

jQuery DatePicker with today as maxDate

I would like to set today's date as a maxdate for jQuery datepicker in order to prevent users from picking date greater than today's date
Emmanuel N
  • 7,350
  • 2
  • 26
  • 36
65
votes
8 answers

How to set minDate to current date in jQuery UI Datepicker?

This is my code and it is not working correctly. I want to set minDate to the current date. How can I do it? $("input.DateFrom").datepicker({ changeMonth: true, changeYear: true, dateFormat: 'yy-mm-dd', maxDate: 'today', …
Ejaz Karim
  • 3,676
  • 6
  • 36
  • 49
61
votes
10 answers

How to format date with hours, minutes and seconds when using jQuery UI Datepicker?

Is it possible to format a date with jQuery UI Datepicker as to show hours, minutes and seconds? This is my current mockup: $(function() { $('#datepicker').datepicker({ dateFormat: 'yyy-dd-mm HH:MM:ss' }).val(); });
59
votes
7 answers

Setting min date in jQuery datepicker

Hi I want to set min date in my jQuery datepicker to (1999-10-25). So I tried the below code it's not working. $(function () { $('#datepicker').datepicker({ dateFormat: 'yy-mm-dd', showButtonPanel: true, changeMonth:…
user1184777
  • 987
  • 2
  • 19
  • 38
55
votes
7 answers

jQuery-UI datepicker default date

I have a problem with the jQuery-UI datepicker, I have searched and searched but I didn't find the answer. I have the following code: