鼠标双击后移开滚动
<!-- 要实现此效果需要 1 个步骤: -->
<!-- 第 1 步: -->
<!-- 把下面的代码加到<BODY></BODY>区域中: -->
<script language="javascript" type="text/javascript">
<!--
var cntr=0
var intervalid
var max_height=500 //the height of the page
//adjust the max_height with the height of your page
//It scrolls about 25 pixels per second
function do_scroll() {
cntr+=6
self.scroll(0,cntr)
if(cntr >max_height) {
cntr =-5
}
//restart the scrolling
if(cntr<0){
cntr+=6
}
}
//stop the scroll
function clear_interval(){
clearInterval(intervalid)
return false
}
function loop_scroll(){
intervalid=setInterval("do_scroll()",250)
status="!!!!!!!!!!! MOUSEOVER TO STOP AUTOSCROLL,MOUSEOUT TO RESTART !!!!!!!!!!!!"
return false
}
//-->
</script>
<script language="javascript">
<!--
document.onmouseover=clear_interval
document.onmouseout=loop_scroll
-->
</script>