實(shí)例如下:
<!doctype html><html><head><meta charset="utf-8"><title></title></head><body><script src="http://code.jquery.com/jquery-1.11.0.min.js"></script><div id="broadcast" class="bar" name="giftactive"><div style="float:left"><strong>間隔滾動(dòng)效果:</strong></div><div id="demo" style="overflow:hidden;height:22px;line-height:22px;"><ul class="mingdan" id="holder"><li><a href="#" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" target="_blank">aaaaaa</a></li><li><a href="#" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" target="_blank">bbbbbb</a></li><li><a href="#" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" target="_blank">cccccc</a></li><li><a href="#" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" target="_blank">dddddd</a></li><li><a href="#" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" target="_blank">eeeeee</a></li></ul></div></div><script type="text/javascript">function AutoScroll(obj) {$(obj).find("ul:first").animate({marginTop: "-22px"}, 500, function() {$(this).css({ marginTop: "0px" }).find("li:first").appendTo(this);});}$(document).ready(function() {setInterval('AutoScroll("#demo")', 1000)});</script></body></html>以上這篇仿京東快報(bào)向上滾動(dòng)的實(shí)例就是小編分享給大家的全部?jī)?nèi)容了,希望能給大家一個(gè)參考,也希望大家多多支持武林網(wǎng)。
新聞熱點(diǎn)
疑難解答
圖片精選
網(wǎng)友關(guān)注