不能暫停啊,求大神指導(dǎo)
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>計(jì)時(shí)器</title>
<script type="text/javascript">
? ?function clock(){
? ? ? var time=new Date();? ? ? ? ? ? ? ? ??
? ? ? document.getElementById("clock").value = time;
? ?}
? ? var i=setInterval("clock()",100);?
</script>
</head>
<body>
? <form>
? ? <input type="text" id="clock" size="50"? />
? ? <input type="button" value="Stop" onclick="clearInterval(i)"/>
? </form>
</body>
</html>
2018-08-20
這個(gè)估計(jì)又是編輯器問(wèn)題,你用自己的編輯器應(yīng)該沒(méi)問(wèn)題的。有時(shí)候多提交幾次有時(shí)對(duì)有時(shí)就錯(cuò)。
2018-08-03
行吧,又是編輯器的問(wèn)題