<script language=javascript>
<!--function start(){
opentime=new Date();
}function a(){
nowtime=new date();
kaishitime=(nowtime.getTime()-opentime.getTime());
seconds=Math.round(kaishitime/1000);
if(seconds>5)
alert("超时");
else
alert("未超时");
}
-->
</sctipt>
<body onload=start()>
<input type=button value=开始 onclick=a()>