代码如下:
<div id="mar" onmouseover="clearInterval(inter);" style="overflow: hidden; height: 180px; width: 200px" onmouseout="inter=setInterval(qswhMarquee,30);">
<div id="mar1">
<table cellSpacing="0" cellPadding="0" width="101%" border="0" id="table2">
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="#">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="/">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="/">向上滚动代码</a></td>
</tr>
<tr>
<td class="tj_sp02"><a class="blackno" target="blank" href="/">向上滚动代码</a></td>
</tr>
</table>
</div>
<div id="mar2"> </div>
</div>
<SCRIPT language=javascript>
var speed=10
var t=mar.scrollTop
mar2.innerHTML=mar1.innerHTML
function qswhMarquee(){
if(mar2.offsetTop-mar.scrollTop<=0)
mar.scrollTop-=mar1.offsetHeight
else
mar.scrollTop++
}
inter=setInterval(qswhMarquee,30)
</SCRIPT>
最新评论