<ul id="tu87_index_comments_tips" style="height:305px;overflow: hidden;">
<span class="firstli"></span>
<!--列表-->
<li><a href="#" target="_black" title="#">标题内容</a></li>
<!--列表 end-->
</ul>
<script>
jQuery(document).ready(function(e) {
var timer = setInterval("tips_scroll()",3500);
jQuery("#tu87_index_comments_tips li:gt(4)").css("height","0");
jQuery("#tu87_index_comments_tips").bind("mouseover",function(){
clearInterval(timer)
});
jQuery("#tu87_index_comments_tips").bind("mouseout",function(){
timer = setInterval("tips_scroll()",3500);
});
});
//最新评论滚动
function tips_scroll(){
var _text = "<li>" + jQuery("#tu87_index_comments_tips li:last").html() + "</li>"
jQuery("#tu87_index_comments_tips .firstli").after(_text);
jQuery("#tu87_index_comments_tips li").eq(0).css("height","auto");
var _height = jQuery("#tu87_index_comments_tips li").eq(0).height();
jQuery("#tu87_index_comments_tips li").eq(0).animate({"height":0},0,function(){
jQuery(this).animate({"height":_height},1000)
jQuery("#tu87_index_comments_tips li").eq(5).animate({"height":0},1000,function(){
jQuery("#tu87_index_comments_tips li").last().remove();
})
})
}
</script>
|
版权声明: 本站资源均来自互联网或会员发布,如果侵犯了您的权益请与我们联系,我们将在24小时内删除!谢谢!
转载请注明: discuz 元素上下单行滚动效果