我想在首页加一个图片无缝向下滚动的SQL 标签:具体代码如下:
查询语句:select TOP 6 ID,Tid,Title,PhotoUrl from KS_Photo where rolls=1 order by id desc
循环体:
div id=demo style="overflow:hidden; width:159px; height:340px;">
<DIV id=demo1>
[loop=6]
<a href="{$Field(Tid,GetClassUrl,2,1)}"><img border="0" src="{$Field(PhotoUrl,Text,0,...,0,)}"></a>
[/loop]
</DIV>
<DIV id=demo2> <SCRIPT>
var ii=0;t=demo.scrollTop
demo2.innerHTML=demo1.innerHTML
function qswhMarquee(){
if (ii==1)return
if(demo2.offsetTop-demo.scrollTop<=0)
demo.scrollTop-=demo1.offsetHeight
else
demo.scrollTop++
}
setInterval(qswhMarquee,60)
</SCRIPT></DIV>
</DIV>
前台调用:{SQL_首页滚动图片()} ,可是光有图片,不滚动,不知道是怎么回事?