用jQuery闪烁一个div [英] Blink an div with jquery
本文介绍了用jQuery闪烁一个div的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我如何使div闪烁.我将鼠标悬停在div元素上.我该如何使用jQuery. div是向上闪烁还是向下闪烁.然后十秒钟.
How can i blink a div. I have a hover on the div element. How can i make with jQuery. That the div is blink up and blink down. And then on the 10 seconds.
谢谢
推荐答案
您正在寻找类似这样的东西吗?此代码将使div每隔10秒出现和消失:
Is something like this what you are looking for? This code will make the div appear and disappear every 10 seconds:
<script type="text/javascript">
var blink = function(){
$('#blinker').toggle();
};
$(document).ready(function() {
setInterval(blink, 10000);
});
</script>
<div id="blinker">This will blink</div>
这篇关于用jQuery闪烁一个div的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文