测试<html>
<head>
<script type="text/javascript">function timedText()
{var t1=setTimeout("document.getElementById('txt').value='2 秒'",2000)var t2=setTimeout("document.getElementById('txt').value='4 秒'",4000)var t3=setTimeout("document.getElementById('txt').value='6 秒'",6000)}</script></head><body><form><input type="button" value="显示计时的文本" onClick="timedText()"><input type="text" id="txt"></form><p>点击上面的按钮。输入框会显示出已经逝去的时间(2、4、6 秒)。</p></body></html>
- 4 回答
- 0 关注
- 695 浏览
添加回答
举报
0/150
提交
取消