I 'd writen something on the screen with setinterval(), and the results are queueing on the screen. I want to refresh it every seconds and have just one on the screen at a time. Any ideas? setInterval("display()",1000);

有帮助吗?

解决方案

Use an iframe or object to load a document,

<iframe src="seconder.html"></iframe>
<object data="seconder.html"></object>

which includes a meta refresh pragma:

<!doctype html>
 <html>
  <head>
    <!--One second meta refresh--> 
    <meta http-equiv="Refresh" content="1">
  </head>
  <body>
     <!--
     ...
     ...
     -->
  </body>
 </html>

References

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top