JS连续横向滚动
<div align="center">
<div id=demo style=overflow:hidden;height:150;width:590>
<table align=left cellpadding=0 cellspace=0 border=0 width="100%">
<tr>
<td id=demo1 valign=top width="100%">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="http://jiee.cn/images/test1.jpg">
<img src="http://jiee.cn/images/test2.jpg">
<img src="http://jiee.cn/images/test1.jpg">
<img src="http://jiee.cn/images/test2.jpg">
<img src="http://jiee.cn/images/test1.jpg">
<img src="http://jiee.cn/images/test2.jpg">
</td>
</tr>
</table>
</td>
<td id=demo2 valign=top width="0"></td>
</tr>
</table>
</div>
<script>
var speed=1
demo2.innerHTML=demo1.innerHTML
function Marquee(){
if(demo2.offsetWidth-demo.scrollLeft<=0)
demo.scrollLeft-=demo1.offsetWidth
else{
demo.scrollLeft++
}
}
var MyMar=setInterval(Marquee,speed)
demo.onmouseover=function() {clearInterval(MyMar)}
demo.onmouseout=function() {MyMar=setInterval(Marquee,speed)}
</script>
</div>
[此贴子已经被作者于2007-2-4 14:32:35编辑过]