<div class="codetitle"> <span><a style="CURSOR: pointer" data="72510" class="copybut" id="copybut72510" onclick="doCopy('code72510')"><u>複製程式碼</u></a></span> 程式碼如下:</div> <div class="codebody" id="code72510"> <br><br> <br> <br> <br> <script type="text/javascript"><BR> function bodyLoad(){<br><br> 🎜 > var mm=dateTime.getMinutes();//分鐘<BR> var ss=dateTime.getSeconds(); /年份<BR> var MM=dateTime.getMonth() 1; //月份-因為1月這個方法回傳為0,所以加1<BR> var dd=dateTime.getDate();//日數<>< dateTime.getDay();//週(0~6,0表示星期日)<br> var days=[ "日", "一", "二", "三", "四", "五", "六",]<br><BR> document.getElementById("date").innerHTML=yy "年" MM "月yId("time ").innerHTML=hh "時" mm "分" ss "秒";<BR><br> setTimeout(bodyLoad,1000);<> setTimeout(bodyLoad,1000);<> 🎜> <body onload="bodyLoad()"><br> <span id="date" ><BR> <br> <br><BR></script> </div>