文件名称:时间控件,个人喜欢用的js时间控件
文件大小:15KB
文件格式:RAR
更新时间:2015-10-19 06:53:38
时间控件
js时间控件,用起来很方便! Calendar = function (mondayFirst, dateStr, onSelected, onClose) { // member variables this.activeDiv = null; this.currentDateEl = null; this.checkDisabled = null; this.timeout = null; this.onSelected = onSelected || null; this.onClose = onClose || null; this.dragging = false; this.hidden = false; this.minYear = 1970; this.maxYear = 2050; this.dateFormat = Calendar._TT["DEF_DATE_FORMAT"]; this.ttDateFormat = Calendar._TT["TT_DATE_FORMAT"]; this.isPopup = true; this.weekNumbers = false;//true;//不要当前周日期 this.mondayFirst = mondayFirst; this.dateStr = dateStr; this.ar_days = null; // HTML elements this.table = null; this.element = null; this.tbody = null; this.firstdayname = null; // Combo boxes this.monthsCombo = null; this.yearsCombo = null; this.hilitedMonth = null; this.activeMonth = null; this.hilitedYear = null; this.activeYear = null; // Information this.dateClicked = false; // one-time initializations if (!Calendar._DN3) { // table of short day names var ar = new Array(); for (var i = 8; i > 0;) { ar[--i] = Calendar._DN[i].substr(0, 3); } Calendar._DN3 = ar; // table of short month names ar = new Array(); for (var i = 12; i > 0;) { ar[--i] = Calendar._MN[i].substr(0, 3); } Calendar._MN3 = ar; } }; // ** constants /// "static", needed for event handlers. Calendar._C = null; /// detect a special case of "web browser" Calendar.is_ie = ( /msie/i.test(navigator.userAgent) && !/opera/i.test(navigator.userAgent) ); // short day names array (initialized at first constructor call) Calendar._DN3 = null; // short month names array (initialized at first constructor call) Calendar._MN3 = null; // BEGIN: UTILITY FUNCTIONS; beware that these might be moved into a separate // library, at some point.
【文件预览】:
js时间控件
----calendar-zh.js(1KB)
----mnext.gif(53B)
----yprev.gif(61B)
----mprev.gif(53B)
----ynext.gif(60B)
----close.gif(77B)
----calendar-setup.js(4KB)
----calendar.js(39KB)
----calendar.css(5KB)