1
<
script language
=
Javascript
>
2 function showTime()
3 {
4 var now = new Date()
5 document.write( " 现在是 " + now.getYear() + " 年 " + (now.getMonth() + 1 ) + " 月 " + now.getDate()
6
7 + " 日 " + now.getHours() + " 时 " + now.getMinutes() + " 分 " + now.getSeconds() + " 秒 " )
8 }
9
10 < / script>
如果要动态显示自已加个timer好了。呵呵
2 function showTime()
3 {
4 var now = new Date()
5 document.write( " 现在是 " + now.getYear() + " 年 " + (now.getMonth() + 1 ) + " 月 " + now.getDate()
6
7 + " 日 " + now.getHours() + " 时 " + now.getMinutes() + " 分 " + now.getSeconds() + " 秒 " )
8 }
9
10 < / script>