67,513
社区成员
发帖
与我相关
我的任务
分享
<html>
<head>
<title></title>
</head>
<body>
<input type="button" value="刷新" onclick="document.getElementById('iframe1').src='bb.html'">
<iframe id="iframe1" src="bb.html"></iframe>
</html>
<div id="div1"></div>
<script>
var counter = 0;
function showCounter(){
document.getElementById("div1").innerHTML = counter;
counter++;
setTimeout("showCounter()",1000);
}
window.onload = showCounter;
</script>