日期:2014-05-17  浏览次数:20893 次

请教高手,多组图片一起翻动的效果,类似CSDN首页显示,不同的是多组一起
请教高手,多组图片一起翻动的效果,类似CSDN首页显示,不同的是多组一起
[第一组图片翻动效果]   [第二组图片翻动效果]   [第三组图片翻动效果]

------解决方案--------------------
不是很明白你的意思
给一个你看下
<div id=demo style= "width:300; overflow:hidden ">
<table>
<tr>
<td id=demo1>
<a href= "images/1.jpg " > <img src= "images/1.jpg " width=100 height= "100 " border= "0 "> </a> &nbsp;
<a href= "images/2.jpg " > <img src= "images/2.jpg " width=100 height= "100 " border= "0 "> </a> &nbsp;
<a href= "images/3.jpg " > <img src= "images/3.jpg " width=100 height= "100 " border= "0 "> </a> &nbsp;
<a href= "images/4.jpg " > <img src= "images/4.jpg " width=100 height= "100 " border= "0 "> </a> </td>
<td id=demo2> </td>
</tr>
</table>
</div>

<script language= "javascript ">
var speed=10
demo2.innerHTML=demo1.innerHTML
function Marquee(){
if(demo.scrollLeft-demo2.offsetWidth> =0)demo.scrollLeft-=demo2.offsetWidth
else{
demo.scrollLeft++
}
}
var MyMar=setInterval(Marquee,speed)
demo.onmouseover=function(){clearInterval(MyMar);}
demo.onmouseout=function(){MyMar=setInterval(Marquee,speed);}
</script>