js
var tab = document.getElementById("content_wrap");
var tab1 = document.getElementById("scroll_img");
var tab2 = document.getElementById("scrool_img_cp");
tab2.innerHTML=tab1.innerHTML;
function Marquee() {
if(tab2.offsetWidth-tab.scrollLeft<=0)
tab.scrollLeft-=tab1.offsetWidth
else{
tab.scrollLeft++;
}
}
var MyMar=setInterval(Marquee,speed);
tab.onmouseover=function(){clearInterval(MyMar)};
tab.onmouseout=function(){MyMar=setInterval(Marquee,speed)}
function Marquee(){
if(tab2.offsetWidth-tab.scrollLeft<=0)
tab.scrollLeft-=tab1.offsetWidth
else{
tab.scrollLeft++;
}
}
var MyMar=setInterval(Marquee,speed);
tab.onmouseover=function() {clearInterval(MyMar)};
tab.onmouseout=function() {MyMar=setInterval(Marquee,speed)};