发些滚动的代码(2)_风讯Cms教程
教程Tag:暂无Tag,欢迎添加,赚取U币!
icefable1.innerHTML=icefable2.innerHTML icefable2.innerHTML;
setInterval("scrollUp()",50);
}
function scrollUp(){
if(stopscroll==true) return;
currentTop =1;
if(currentTop==17)
{
stoptime =1;
currentTop-=1;
if(stoptime==50)
{
currentTop=0;
stoptime=0;
}
}
else {
preTop=icefable1.scrollTop;
icefable1.scrollTop =1;
if(preTop==icefable1.scrollTop){
icefable1.scrollTop=icefable2.offsetHeight-marqueesHeight;
icefable1.scrollTop =1;
}
} }
init_srolltext();
</SCRIPT> 3:横向滚动 <div id=demo style=overflow:hidden;height:99;width:727;>
<div id=demo1>{FS_全站图片}
</div>
<div id=demo2></div>
</div>
<script>
var speed=20
demo2.innerHTML=demo1.innerHTML
function Marquee3(){
if(demo2.offsetTop-demo.scrollTop<=0)
demo.scrollTop-=demo1.offsetHeight
else{
demo.scrollTop
}
}
var MyMar=setInterval(Marquee3,speed)
demo.onmouseover=function() {clearInterval(MyMar)}
demo.onmouseout=function() {MyMar=setInterval(Marquee3,speed)}
</script> 9 7 3 1 2 4 8 :
相关风讯Cms教程:
- 相关链接:
- 教程说明:
风讯Cms教程-发些滚动的代码(2)。