<html xmlns=" http://www.w3.org/1999/xhtml">
<head>
<title>new document </title>
<meta name="generator" content="editplus" />
<meta name="author" content="" />
<meta name="keywords" content="" />
<meta name="description" content="" />
<script type="text/javascript">
<!--
setInterval("showTime()",1000)
function showTime()
{
var wk = ["星期日","星期一","星期二","星期三","星期四","星期五","星期六"]
var date = new Date()
var msg = "今天是:" + date.getFullYear()+"年"
msg += date.getMonth()+1 +"月"
msg += date.getDate() + "日"
msg += wk[date.getDay()]+" "
msg += date.getHours()+":" + date.getMinutes()+":"+date.getSeconds()
document.getElementById("time").innerText = msg
}
//-->
</script>
</head>
<body>
<span id="time"></span>
</body>
</html>
<script>
window.onload=function(){
function toer(n){
if(n<10){
return "0"+n
}
else{
return ""+n
}
}
setInterval(function(){
var nowtime=document.getElementById("nowtime")
var odate=new Date()
var aa=toer(odate.getHours())+": "+toer(odate.getMinutes())+": "+toer(odate.getSeconds())
nowtime.innerHTML = aa
},1000)
}
</script>