jquery UI 1.72のdatepicker
1325 ワード
<br>$(function() {
<br>var options = {
<br>changeMonth: true, //
<br>changeYear: true, //
<br>firstDay: 0, // ( )( :0~6)
<br>showOtherMonths: true, //
<br>showMonthAfterYear: false, //
<br>prevText: " ", //
<br>nextText: ' ', //
<br>stepMonths: 2, // “ ” “ ”, 2
<br>navigationAsDateFormat: true,
<br>showCurrentAtPos: 3, // 3
<br>showOn: 'both',
<br>//minDate/maxDate/hideIfNoPrevNext
<br>minDate:'-10', //
<br>maxDate: '35',
<br>hideIfNoPrevNext: false, // prev next , maxDate minDate
<br>// defaultDate: 2, //
<br>gotoCurrent: true,
<br>numberOfMonths: 2, // 2 (2 )
<br>yearRange: '2009:2019' //
<br>};
<br>//
<br>$('#datePicker').datepicker(options);
<br>//
<br>$('#datePicker').datepicker('getDate');
<br>
<br>//
<br>$('#datePicker').datepicker('setDate', '+1m +1d')
<br>})
<br>