// START CONFIG

// scroller height
var ticker_height = 135;

var ticker_starting_position = 100;

// scroller speed
var sspeed = 2;

// END CONFIG



var resumesspeed = sspeed;

function startticker(ticker_text)
{
	if (document.all) iemarquee(ticker, ticker_text);
	else if (document.getElementById)
		ns6marquee(document.getElementById('ticker'), ticker_text);
}

function iemarquee(whichdiv, ticker_text)
{
	iediv = eval(whichdiv)
	iediv.style.pixelTop = ticker_starting_position;
	iediv.innerHTML = ticker_text;
	sizeup = iediv.offsetHeight;
	ieslide();
}

function ieslide()
{
	if (iediv.style.pixelTop >= sizeup*(-1)) {
	    iediv.style.pixelTop -= sspeed;
	    setTimeout("ieslide()", 100);
	} else {
        iediv.style.pixelTop = ticker_height;
        ieslide();
	}
}

function ns6marquee(whichdiv, ticker_text)
{
    ns6div = eval(whichdiv);
    ns6div.style.top = ticker_starting_position + "px";
    ns6div.innerHTML = ticker_text;
    sizeup = ns6div.offsetHeight;
    ns6slide();
}

function ns6slide()
{
    if (parseInt(ns6div.style.top) >= sizeup * (-1)) {
        theTop = parseInt(ns6div.style.top) - sspeed;
        ns6div.style.top = theTop + "px";
        setTimeout("ns6slide()", 100);
    } else {
        ns6div.style.top = ticker_height + "px";
        ns6slide();
    }
}

function initTicker(containerNode) {
	if (!document.getElementById)
		return;
	if (document.getElementById(containerNode)) {
		startticker(document.getElementById(containerNode).innerHTML);
	}
}

