一个在时间选择上很有用的代码(3)
2008-02-23 07:51:21来源:互联网 阅读 ()
for (i=0; i<12; i )
write("<option value='" (i 1) "'>" gMonths[i] "</option>");
write("</SELECT>");
write(" <input type='button' name='PrevMonth' value='>' style='height:20;width:20' onclick='fNextMonth()'>");
write("</td>");
write("</TR><TR>");
write("<td align='center'>");
write("<DIV style='background-color:teal'><table width='100%' border='0'>");
fDrawCal(giYear, giMonth, 0, '0');
write("</table></DIV>");
write("</td>");
write("</TR><TR><TD align='center'>");
//
write(" <select name='tbSelHour' onChange='fTime(tbSelHour,tbSelSec,tbSelMin)' Victor='Won'>");
for(i=0;i<24;i )
{
if(i<10)
{
write("<OPTION value='0" i "'>" i "时</OPTION>");
}
else
{
write("<OPTION value='" i "'>" i "时</OPTION>");
}
}
write("</SELECT>");
write(" <select name='tbSelSec' onChange='fTime(tbSelHour,tbSelSec,tbSelMin)' Victor='Won'>");
for(i=0;i<60;i )
if(i<10)
{
write("<OPTION value='0" i "'>" i "分</OPTION>");
}
else
{
write("<OPTION value='" i "'>" i "分</OPTION>");
}
write("</SELECT>");
write(" <select name='tbSelMin' onChange='fTime(tbSelHour,tbSelSec,tbSelMin)' Victor='Won'>");
for(i=0;i<60;i )
if(i<10)
{
write("<OPTION value='0" i "'>" i "秒</OPTION>");
}
else
{
write("<OPTION value='" i "'>" i "秒</OPTION>");
}
write("</SELECT>");
//
write("<TABLE width='100%'><TR><TD align='center'>");
write("<font size='2' onclick='fSetDate(0,0,0)' onMouseOver='this.style.color=gcToggle' onMouseOut='this.style.color=0'> 清空</font>");
//B style='cursor:hand'被替换为font size='2'
write("</td><td algin='center'>");
write("<font size='2' onclick='fSetDate(giYear,giMonth,giDay)' onMouseOver='this.style.color=gcToggle' onMouseOut='this.style.color=0'>今天: " giYear "-" giMonth "-" giDay "</font>");
//B style='cursor:hand'被替换为font size='2'
write("</td></tr></table>");
write("</TD></TR>");
write("</TABLE></Div>");
}
HTML:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<style type="text/css">
<!--
.style1 {font-size: 10px}
-->
</style>
</head>
<body>
<body bgcolor="#D6D3CE">
<script language="javascript" src="time.js"> //调用JS代码
</script>
<div align="center">
<center>
<table width="248" border="0">
<tr>
<td nowrap width="599"><span class="style1">选择时间</span>:<input class="input" onclick="fPopCalendar(regdate,regdate);return false" type="text" name="regdate" size="30"></td>
</tr>
</table>
</center>
</div>
</body>
</body>
</html>
标签:
版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com
特别注意:本站所有转载文章言论不代表本站观点,本站所提供的摄影照片,插画,设计作品,如需使用,请与原作者联系,版权归原作者所有
IDC资讯: 主机资讯 注册资讯 托管资讯 vps资讯 网站建设
网站运营: 建站经验 策划盈利 搜索优化 网站推广 免费资源
网络编程: Asp.Net编程 Asp编程 Php编程 Xml编程 Access Mssql Mysql 其它
服务器技术: Web服务器 Ftp服务器 Mail服务器 Dns服务器 安全防护
软件技巧: 其它软件 Word Excel Powerpoint Ghost Vista QQ空间 QQ FlashGet 迅雷
网页制作: FrontPages Dreamweaver Javascript css photoshop fireworks Flash
