var middlew21 = document.getElementById("middlew21"); var bottomw21 = document.getElementById("bottomw21"); middlew21.innerHTML = middlew21.innerHTML; middlew21.innerHTML = middlew21.innerHTML + middlew21.innerHTML + middlew21.innerHTML; bottomw21.innerHTML = middlew21.innerHTML + middlew21.innerHTML + middlew21.innerHTML; function marqueecw21() { if (document.getElementById('bottomw21').offsetTop - document.getElementById('topw21').scrollTop <= 0) { document.getElementById('topw21').scrollTop -= document.getElementById('middlew21').offsetHeight; } else { document.getElementById('topw21').scrollTop += 1; } } function startscrollcw21() { var scrollobjc = setInterval(marqueecw21, 150); document.getElementById('topw21').onmouseover = function() { clearInterval(scrollobjc); }; document.getElementById('topw21').onmouseout = function() { scrollobjc = setInterval(marqueecw21, 150); }; } startscrollcw21();