求一个JS日期控件。精确到月就行了

来源:百度知道 编辑:UC知道 时间:2024/06/18 01:15:25

用的时候先在<head></head>插入

<SCRIPT src="Images/setday.js"></SCRIPT>
然后输入框

<INPUT id="starttime2" onclick="setday(this)" size="12" name="starttime" runat="server">

setday.js代码如下:

<SCRIPT>
document.writeln('<div id=meizzDateLayer style="position: absolute; width: 142; height: 166; z-index: 9998; display: none">');
document.writeln('<span id=tmpSelectYearLayer style="z-index: 9999;position: absolute;top: 2; left: 18;display: none"></span>');
document.writeln('<span id=tmpSelectMonthLayer style="z-index: 9999;position: absolute;top: 2; left: 75;display: none"></span>');
document.writeln('<table border=0 cellspacing=1 cellpadding=0 width=142 height=160 bgcolor=#000000 onselectstart="return false">');
document.writeln(