<?php header("Content-Type: text/javascript"); ?>
 
window.onload=init;
 
var flag=0;
 
function $$(o){ return document.getElementById(o);}
 
function init(){
 
    var w=screen.width;
 
    $$('bannerbody').style.left=((w-600)/2)+"px";
 
    $$('bannerbody').style.visibility="visible";
 
    setInterval("scroll()",1);
 
}
 
function scroll(){
 
    if($$('sdiv')){
 
        var top=parseInt($$('sdiv').offsetTop);
 
        var h=parseInt($$('id1').offsetTop);
 
        t=top*(-1);
 
        var chk=(h*len);
 
        if(t>chk){
 
            $$('sdiv').style.position="relative";
 
            $$('sdiv').style.top=h+"px";    
 
            top=parseInt($$('sdiv').offsetTop);
 
        }
 
        if(flag==0){
 
            $$('sdiv').style.position="relative";
 
            $$('sdiv').style.top=(top-1)+"px";
 
        }
 
    }
 
}
 
function onOver(){
 
    flag=1;
 
}
 
function onOut(){
 
    flag=0;
 
}
 
 
 |