var copyspeed = marqueespeed;
var marqueetop;

var pausespeed = (pauseit == 0) ? copyspeed : 0;

document.write('<span id="nttemp" style="visibility: hidden; position: absolute; top: -9000px; left: -100px; width:' + marqueewidth + ';">' + marqueecontent + '</span>');
var actualheight = '';
var cross_marquee;

function populate(){
	cross_marquee = document.getElementById('iemarquee');
	cross_marquee.style.left = 0;
	marqueetop = parseInt(marqueeheight) + 8;
	cross_marquee.style.top = marqueetop + 'px';
	cross_marquee.innerHTML = marqueecontent;
	actualheight = document.getElementById('nttemp').offsetHeight;
	lefttime = setInterval(scrollmarquee, marqueeinterval);
}

addLoadEvent(populate); // add function populate() as onload handler

function scrollmarquee() {
	if (marqueetop > (actualheight * (-1) + 8)) {
		marqueetop = marqueetop - copyspeed;
		cross_marquee.style.top = Math.round(marqueetop) + 'px';
	} else {
		marqueetop = parseInt(marqueeheight) + 8;
		cross_marquee.style.top = Math.round(marqueetop) + 'px';
	}
}

document.write('<table border="0" cellspacing="0" cellpadding="0"><tr><td>');
document.write('<div style="position: relative; width:' + marqueewidth + '; height: ' + marqueeheight + '; overflow: hidden;">');
document.write('<div style="position: absolute; width: ' + marqueewidth + '; height: ' + marqueeheight + '; background-color: ' + marqueebgcolor + ';" onMouseover="copyspeed = pausespeed" onMouseout="copyspeed = marqueespeed">');
document.write('<div id="iemarquee" style="position: absolute; left: 0px; top: 0px; width: ' + marqueewidth + ';"></div>');
document.write('</div></div>');
document.write('</td></tr></table>');
