-
-
Druid WensleydaleA wonderful serenit of my entire soul. 20 May 2018, 15:32
- Inverness McKenzieA wonderful serenit of my entire soul. 20 May 2018, 15:32
- McKenzie InvernessA wonderful serenit of my entire soul. 20 May 2018, 15:32
- Inverness McKenzieA wonderful serenit of my entire soul. 20 May 2018, 15:32
- Show All Notifications
-
-
George Martin
Hello, Welcome here
Date picker default
The basic setup requires targetting an input
element and invoking the picker: $('.datepicker').pickadate()
Date picker default - String sort
Change the month and weekday labels as you find suitable:
weekdaysShort: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'],
showMonthsShort: true
Date picker default - Change button text
Change the text or hide a button completely by passing a falsy value:
today: '',
clear: 'Clear selection',
close: 'Cancel'
Date picker default - Change button text
Change the title
attributes to several elements within the picker:
labelMonthNext: 'Go to the next month',
labelMonthPrev: 'Go to the previous month',
labelMonthSelect: 'Pick a month from the dropdown',
labelYearSelect: 'Pick a year from the dropdown',
selectMonths: true,
selectYears: true
Date picker default - translation
The picker can be extended to add support for internationalization. Translations for over 40 languages are available out of the box, which you can include in one of two ways:
monthsFull: ['Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre'],
weekdaysShort: ['Dim', 'Lun', 'Mar', 'Mer', 'Jeu', 'Ven', 'Sam'],
today: 'aujourd\'hui',
clear: 'effacer'
Date picker default - fomats
Display a human-friendly format and use an alternate one to submit to the server.
format: 'You selecte!d: dddd, dd mmm, yyyy',
formatSubmit: 'yyyy/mm/dd'
Date picker default - pre-filled values
<input data-value="2015/04/20">
Date picker default - editable input
editable: true
Date picker default - select options
selectYears: true, selectMonths: true
Date picker default - select year
You can also specify the number of years to show in the dropdown using an even integer - half before and half after the year in focus:
selectYears: 4
Date picker default - date limits
Using javascript dates :
min: new Date(2015,3,20), max: new Date(2015,7,14)
or using arrays
min: [2015,3,20], max: [2015,7,14]