window.onload = function()
{
        resizeBody();
}

function resizeBody()
{
	    if (isIE6()) {
	    	$("centerDiv").style.padding = "24px";
	    }
        max = 0;

        var bodyDiv = $("centerDiv");
        var h = bodyDiv.offsetHeight+4;
        $('leftSide').style.height = h+"px";
        $('rightSide').style.height = h+"px";
}

function $() {
        var elements = new Array();
        for (var i = 0; i < arguments.length; i++) {
                var element = arguments[i];
                if (typeof element == 'string')
                        element = document.getElementById(element);
                if (arguments.length == 1)
                        return element;
                elements.push(element);
        }
        return elements;
}

function showCalculatorConfirmPopup() {
	$('divMain').className='dimPage';
    $('acceptAgreement').className='lightBox';	

	$('acceptAgreement').style.left = screen.width/4 + "px";
	$('acceptAgreement').style.top = screen.height/4 + "px";
	$('acceptAgreement').style.display = '';
	return;
	}

function sendToCalculator() {
	 window.location.href = '/calculator.php?accept_disclaimer=1';
	}
	
function sendToHome() {
	 window.location.href = '/';
	}
	
function isIE6() {
	var ua = window.navigator.userAgent;

	var msie = ua.indexOf( "MSIE 6" );
	if ( msie > 0 )	{	// is Microsoft Internet Explorer; return version number
		return true;
		}
	else {
		return false;	// is other browser
		}
}