<!--
var bottomShim = 220;
var padding = 0;
if (macIE)
    padding = 0;
else
    padding = 0;

function calc () {
    var prevScroll = 0;
    var distance = 0;
    if (document.all) {
		var btmPosition = bottomPosition.offsetTop - bottomShim;
        // check if the top div is in viewing area. if so align with it
        if (document.body.scrollTop <= topPosition.offsetTop) {
            distance = -1 * ((adStack.style.pixelTop - topPosition.offsetTop) / 2);
            keepMoving (distance);
        }
        // check if the bottom div is in viewing area. if so align with it
        else if ((document.body.clientHeight + document.body.scrollTop) >= btmPosition) {
            distance = (btmPosition - (adStack.style.pixelTop + adStack.offsetHeight)) / 2;
            keepMoving (distance);
        }
        // if neither top nor bottom are in viewing area than scroll with the scrollbar.
        else {
            if ((document.body.scrollTop + adStack.offsetHeight) < btmPosition)
                adStack.style.top = document.body.scrollTop;
        }
    }
    else if (document.layers) {
		var btmPosition = document.layers.bottomPosition.pageY - bottomShim;
        if (self.pageYOffset <= document.layers.topPosition.pageY) {
            distance = -1 * ((document.layers.adStack.pageY - document.layers.topPosition.pageY) / 2);
            keepMoving (distance);
        }
        else if ((window.innerHeight + self.pageYOffset) >= btmPosition) {
            distance = (btmPosition - (document.layers.adStack.pageY + document.adStack.document.height)) / 2;
            keepMoving (distance);
        }
        
        else {
            if ((self.pageYOffset + document.adStack.document.height) < btmPosition)
                document.layers.adStack.pageY = self.pageYOffset;
        }
    }
}

// moves the ad tower on IE browsers
function keepMoving(distance) {
    if (document.all) {
        adStack.style.left = topPosition.offsetLeft + padding;
        adStack.style.pixelTop = adStack.style.pixelTop + distance;
    }
    if (document.layers) {
        document.layers.adStack.pageX = document.layers.topPosition.pageX;
        document.layers.adStack.pageY = document.layers.adStack.pageY + distance;
    }
}

// called on page load to position the ad tower div, make it visible, and 
function posAdDiv() {
    if (document.all)
    {
        document.all.adStack.style.top = topPosition.offsetTop;
        document.all.adStack.style.left = topPosition.offsetLeft + padding;
        document.all.adStack.style.visibility = 'visible';
    }
    if (document.layers)
    {
        document.layers.adStack.pageX = document.layers.topPosition.pageX;
        document.layers.adStack.pageY = document.layers.topPosition.pageY;
        document.layers.adStack.visibility = 'visible';
    }
    // puts calc() on .3 sec intervals
    //interval = window.setInterval('calc()', 300);
} 

function init() {
    /*if (typeof "homepage" == "undefined") {
        syncDivs ();
    }*/
	posAdDiv ();
}    
window.onload = init;
//-->

