返回列表 发帖

数字化的时钟代码

<span id="liveclock" style"=width: 109px; height: 15px"></span>
' E2 z3 X* a  K8 i<SCRIPT language=javascript>  W0 l( U5 P9 g. T, K5 f* F7 W
function www_helpor_net()
& K  i$ U7 I1 X{
8 S% Z1 a# d' Ovar Digital=new Date()
# a. G; Q0 U! \; Y" ivar hours=Digital.getHours()
; ~) `+ O# [2 x+ A% V* k) z5 w. c* gvar minutes=Digital.getMinutes()" R" @1 m5 V: M- |
var seconds=Digital.getSeconds()6 L" i3 ]* k0 S
5 G2 I; `" O4 g, S2 Y) J
if(minutes<=9)  k, k0 {( w* T/ _/ Q
minutes="0"+minutes
0 e, e/ `9 N! N& O" nif(seconds<=9)
& b: l  R7 G6 Q- |seconds="0"+seconds* @: }: w6 ~: A" S2 a2 E
myclock="现在时刻:<font size='5' face='Arial black'>"+hours+":"+minutes+":"+seconds+"</font>"; S+ g% b2 ^" R
if(document.layers){document.layers.liveclock.document.write(myclock)
8 y& x2 `/ U, U; N# c; ]document.layers.liveclock.document.close()6 }1 B2 \: [) p" s8 n
}else if(document.all)
, O$ \1 t* p2 V/ ^' iliveclock.innerHTML=myclock% |% w6 x% k/ v1 {* `' }5 V% h
setTimeout("www_helpor_net()",1000): _0 n" ]$ b: v, P
}, k# {4 K: o1 L8 F
www_helpor_net();
" g1 K- M* j/ m  t5 \3 z//-->9 y& ]& l3 [; Q
</SCRIPT>

返回列表
【捌玖网络】已经运行: