日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 前端技术 > HTML >内容正文

HTML

前端学习(2854):简单秒杀系统学习之settimeout

發(fā)布時間:2023/12/9 HTML 27 豆豆
生活随笔 收集整理的這篇文章主要介紹了 前端学习(2854):简单秒杀系统学习之settimeout 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.
<html> <head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>test</title></head> <body> <h1><font color=blue> 示范網(wǎng)頁 </font> </h1> <p></br> <script>setTimeout("alert('對不起,久等了');", 3000);setTimeout("alert('對不起');",3000); function clearWord() {document.title = ''; } </script><form> <input type="button" value="在狀態(tài)列顯示文字" onClick="document.title='Hello' ,setTimeout('clearWord()', 3000) " /> </form> </body> </html>

<html> <head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <script> x = 0 function countSecond( ) { x = x+1document.fm.displayBox.value=xsetTimeout("countSecond()", 1000) } </script> </head> <body bgcolor=lightcyan text=red> <p> </br><form name=fm> <input type="text" name="displayBox"value="0" size=4 > </form><script> countSecond() </script> </body> </html>

<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title></title></head><body onload="countSecond();"><script>var x = 0;function countSecond(){ if ( x < 20 ) { x = x + 1;document.getElementById("displaySec").value = xsetTimeout("countSecond()", 1000)}}</script><input type="text" id="displaySec" value="0" /></body> </html>

運行結(jié)果

總結(jié)

以上是生活随笔為你收集整理的前端学习(2854):简单秒杀系统学习之settimeout的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。