横向
<script> <BR>var t=demo.scrollWidth <BR>demo1.innerHTML+=demo1.innerHTML <BR>function doMarquee() <BR>{ <BR>demo.scrollLeft=demo.scrollLeft<demo.scrollWidth-demo.offsetWidth?demo.scrollLeft+1:t-demo.offsetWidth <BR>} <BR>function doscroll() <BR>{ <BR> sc=setInterval(doMarquee,20) <BR>} <BR>function stopscroll() <BR>{ <BR> clearInterval(sc) <BR>} <BR>doscroll() <BR></script>
纵向
<script> <BR>var speed=100 <BR>demo2.innerHTML=demo1.innerHTML <BR>function Marquees(){ <BR>if(demo2.offsetTop-demo.scrollTop<=0) <BR>demo.scrollTop-=demo1.offsetHeight <BR>else{ <BR>demo.scrollTop++ <BR>} <BR>} <BR>var MyMars=setInterval(Marquees,speed) <BR>demo.onmouseover=function() { clearInterval(MyMars) } <BR>demo.onmouseout=function() { MyMars=setInterval(Marquees,speed) } <BR>zlselect('6'); <BR></script>