How to Use the jquery UI Datepicker time control (Basic edition) and jquerydatepicker
This article will share with you how to use the jquery ui datepicker time control. You can learn about the ui datepicker time control through examples. Let's take a look:
Effect:
Common scenarios:
1. input box
2. div
Usage:
1. Date limit
$ ("# ResultDiv "). datepicker ({onSelect: function (dateText, inst) {// code: events triggered after Date selection}, minDate: new Date (), // maxDate minimum Date: new Date ($ ("# DateLimit "). val () // maximum date });
2. Chinese
JQuery (function ($) {$. datepicker. regional ['zh-cn'] = {closeText: 'close', prevText: '<last month', nextText: 'Next month> ', currentText: 'Today', monthNames: ['October ', 'October ', 'August 11', 'August 11', 'August 11'], monthNamesShort: ['1', 'two', '3', '4', '5', '6 ', '7', '8', '9', '10', '11', '12'], dayNames: ['sunday', 'monday', 'tues ', 'wedday', 'thurday', 'Friday', 'saturday'], dayNamesShort: ['sunday', 'monday', 'tues', 'wedday', 'thurday ', 'Friday', 'satur'], dayNamesMin: ['day', 'yi', '2', '3', '4', '5 ', '6'], weekHeader: 'Week', dateFormat: 'yy-mm-dd', firstDay: 1, isRTL: false, showMonthAfterYear: true, yearSuffix: 'Year '}; $. datepicker. setDefaults ($. datepicker. regional ['zh-cn']);});
The above is how to use the jquery ui datepicker time control. The content is very simple. The purpose is to let you know about the UI datepicker time control. I hope you will like it, the jquery ui datepicker time control is not over yet. I will continue to learn more in the next article.