分享

时间代码

 勇哥个人图书馆 2012-01-28
时间代码



<DIV align=right>
<SCRIPT language=JavaScript>


document.write('<table width="130" height=70 border=1 cellpadding=0 cellspacing=0><tbody><tr><td

valign=bottom width="300" height=20><p align=center>');
today=new Date();
function initArray(){
this.length=initArray.arguments.length
for(var i=0;i<this.length;i++)
this[i+1]=initArray.arguments[i]  }
document.write("<font color=ff0000>",today.getYear(),"<font color=#ff0000>年","<font

color=#ff0000>",today.getMonth()+1,"<font color=#ff0000>月","<font color=#ff0000>",today.getDate

(),"<font color=#ff0000>日 </FONT>");
var d=new initArray("<font color=#ff0000>星期日","<font color=#ff0000>星期一","<font color=#ff0000>星

期二","<font color=#ff0000>星期三","<font color=#ff0000>星期四","<font color=#ff0000>星期五","<font

color=#ff0000>星期六");
document.write('</p></td></tr><tr> <td width="100" height=20valign=bottom><p align=center>');
document.write(d[today.getDay()+1]);
document.write('</p></td></tr><tr><td width="100" height=30 ><font color=ff0000><p align=center><span

id="liveclock" style"=width: 109px; height: 15px"></span>');
function www_helpor_net()
{
var Digital=new Date()
var hours=Digital.getHours()
var minutes=Digital.getMinutes()
var seconds=Digital.getSeconds()

if(minutes<=9)
minutes="0"+minutes
if(seconds<=9)
seconds="0"+seconds
myclock=hours+":"+minutes+":"+seconds
if(document.layers){document.layers.liveclock.document.write(myclock)
document.layers.liveclock.document.close()
}else if(document.all)
liveclock.innerHTML=myclock
setTimeout("www_helpor_net()",1000)
}
www_helpor_net();
document.write('</p></font></td></tr></tbody></table>');

</SCRIPT>

</DIV>

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约

    类似文章 更多