[Javascript]发布一个自己写的日期控件:DateTimeList
网上免费的日期控件有很多,博客园里也有一个博客园兄弟们的大作!
但个人不喜欢用层出来的东东,因为用层过iframe的话有时窗口不够大时会出现滚动条!
所以用showModalDialog弹出窗口写了个日期选择的JS。
喜欢的朋友可以随意用吧!
下载地址:/Files/HD/DateTimeList/DateTimeList.rar
里头有示例,只在IE6.0里调试通过,别的不知道!^o^
----------------------------------
使用方法:
一:
在所需的要页面的<head></head>区块中加入:<script src="DateTimeList/DateTimeList.js" language="javascript"></script>
二:主调函数:ShowDateTime( this,'DateTime' )或ShowDateTime( this,'Date' )或ShowDateTime( this,'Time' )
例如:
1:
<input type="text" id="txtTime" name="txtTime" onclick="ShowDateTime( this,'DateTime' );"/>
2:
<input type="button" onclick="ShowDateTime( this,'time' );" />
示例截图如下:
![](/images/cnblogs_com/hd/DemoOpus/image1.jpg)
但个人不喜欢用层出来的东东,因为用层过iframe的话有时窗口不够大时会出现滚动条!
所以用showModalDialog弹出窗口写了个日期选择的JS。
喜欢的朋友可以随意用吧!
下载地址:/Files/HD/DateTimeList/DateTimeList.rar
里头有示例,只在IE6.0里调试通过,别的不知道!^o^
----------------------------------
使用方法:
一:
在所需的要页面的<head></head>区块中加入:<script src="DateTimeList/DateTimeList.js" language="javascript"></script>
二:主调函数:ShowDateTime( this,'DateTime' )或ShowDateTime( this,'Date' )或ShowDateTime( this,'Time' )
例如:
1:
<input type="text" id="txtTime" name="txtTime" onclick="ShowDateTime( this,'DateTime' );"/>
2:
<input type="button" onclick="ShowDateTime( this,'time' );" />
示例截图如下:
![](/images/cnblogs_com/hd/DemoOpus/image1.jpg)
![](/images/cnblogs_com/hd/DemoOpus/image2.jpg)