JQuery實(shí)現(xiàn)倒計(jì)時(shí)按鈕具體方法
<head>
<title>test count down button</title>
<script src="http://ajax.aspnetcdn.com/ajax/jquery/jquery-1.5.1.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(function () {
$('#btn').click(function () {
var count = 3;
var countdown = setInterval(CountDown, 1000);
function CountDown() {
$("#btn").attr("disabled", true);
$("#btn").val("Please wait " + count + " seconds!");
if (count == 0) {
$("#btn").val("Submit").removeAttr("disabled");
clearInterval(countdown);
}
count--;
}
})
});
</script>
</head>
<body>
<input type="button" id="btn" value="Submit" />
</body>
有興趣您可以自己實(shí)現(xiàn)一下。
- jquery實(shí)現(xiàn)手機(jī)發(fā)送驗(yàn)證碼的倒計(jì)時(shí)代碼
- jquery簡單倒計(jì)時(shí)實(shí)現(xiàn)方法
- 基于jQuery的倒計(jì)時(shí)實(shí)現(xiàn)代碼
- jQuery實(shí)現(xiàn)倒計(jì)時(shí)跳轉(zhuǎn)的例子
- jQuery倒計(jì)時(shí)代碼(超簡單)
- JQuery實(shí)現(xiàn)倒計(jì)時(shí)按鈕的實(shí)現(xiàn)代碼
- 利用jQuery實(shí)現(xiàn)漂亮的圓形進(jìn)度條倒計(jì)時(shí)插件
- jquery 倒計(jì)時(shí)效果實(shí)現(xiàn)秒殺思路
- jQuery實(shí)現(xiàn)倒計(jì)時(shí)按鈕功能代碼分享
- jQuery實(shí)現(xiàn)倒計(jì)時(shí)功能 jQuery實(shí)現(xiàn)計(jì)時(shí)器功能
相關(guān)文章
jquery1.4.2 for Visual studio 2010 模板文件
剛把最新的1.4.2 版jquery 整理進(jìn)了vs2010,每次建項(xiàng)目就能直接用了.文件好多.累死了..2010-07-07基于jquery實(shí)現(xiàn)的移入頁面上空文本框時(shí),讓它變?yōu)榻裹c(diǎn),移出清除焦點(diǎn)
基于jquery實(shí)現(xiàn)的移入頁面上空文本框時(shí),讓它變?yōu)榻裹c(diǎn),移出清除焦點(diǎn)的實(shí)現(xiàn)代碼。2011-07-07Jquery的hover方法讓鼠標(biāo)經(jīng)過li時(shí)背景變色
鼠標(biāo)經(jīng)過時(shí)讓li背景變色,在某些時(shí)候還是挺實(shí)用的,下面為大家介紹下使用Jquery的hover方法來實(shí)現(xiàn)下,感興趣的朋友可以參考下2013-09-09基于jquery實(shí)現(xiàn)鼠標(biāo)左右拖動(dòng)滑塊滑動(dòng)附源碼下載
這篇文章主要介紹了基于jquery實(shí)現(xiàn)鼠標(biāo)左右拖動(dòng)滑塊滑動(dòng)附源碼下載 的相關(guān)資料,需要的朋友可以參考下2015-12-12基于JQuery 滑動(dòng)與動(dòng)畫的說明介紹
本篇文章小編為大家介紹,基于JQuery 滑動(dòng)與動(dòng)畫的說明介紹。需要的朋友參考下2013-04-04