把以下代码做成标签就可以实现无缝隙图片滚动了
<div id=fx_gun_left style=overflow:hidden;height:100;width:90;background:#214984;color:#ffffff>
<table cellpadding="0" cellspacing="0" border="0">
<tr><td id="fx_gun_left1" valign="top" align="center">
<table cellpadding="2" cellspacing="0" border="0">
<tr align="center">
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
<td><img src="http://www.daixiao360.cn/skin/cmsmoban/images/logo.gif"></td>
</tr>
</table>
</td>
<td id="fx_gun_left2" valign="top"></td>
</tr>
</table>
</div>
<script>
var speed=30//速度数值越大速度越慢
fx_gun_left2.innerHTML=fx_gun_left1.innerHTML
function Marquee3(){
if(fx_gun_left2.offsetWidth-fx_gun_left.scrollLeft<=0)
fx_gun_left.scrollLeft-=fx_gun_left1.offsetWidth
else{
fx_gun_left.scrollLeft++
}
}
var MyMar3=setInterval(Marquee3,speed)
fx_gun_left.onmouseover=function() {clearInterval(MyMar3)}
fx_gun_left.onmouseout=function() {MyMar3=setInterval(Marquee3,speed)}
</script>
声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。
评论(0)