function fixLayout()
{
	var cont = document.getElementById("container");
	var contHeight = cont.offsetHeight;
	wHeight = window.innerHeight;	
	if (document.all && !window.opera) {
		wHeight = document.documentElement.clientHeight;
	}
	var temp = wHeight - contHeight;
	var temp = wHeight - contHeight;
	if (temp > 0)
	{
		cont.style.marginTop = (wHeight - contHeight) / 2 + "px";
	}
	else {
		cont.style.marginTop = "0px";
	}
}
if (window.addEventListener){
	window.addEventListener("resize", fixLayout, false);
	window.addEventListener("load", fixLayout, false);
}
else if (window.attachEvent){
	window.attachEvent("onresize", fixLayout);
	window.attachEvent("onload", fixLayout);
}

// Global XMLHttpRequest variable
			var request = null;
			
			// This function loads the specified URL and inserts the result of it (or an error message)
			// into the "content" div.  It uses a synchronous XMLHTTPRequest to do so and returns false
			// if an error occurs loading the URL.
			function loadURL(url)
			{
				// Variable for response content
				var inner = '';
				
				// Return value
				var value = false;
				
				// Create an XMLHttpRequest object or ActiveX control
				if (window.XMLHttpRequest) 
				{
					request = new XMLHttpRequest();
				}
				else if (window.ActiveXObject)
				{
					request = new ActiveXObject("Microsoft.XMLHTTP");
				}
				
				// If XMLHTTPRequest is supported
				if (request)
				{
					// Set up synchronous request
					request.open("GET", url, false);
					
					// Send synchronous request
					request.send(null);
					
					// Check the status
					if (request.status == 200)
					{
						// Success
						inner = request.responseText;
						value = true;
					}
					else
					{
						// Error
						inner = 'Error: ' + request.status + ' ' + request.statusText;
					}
				}
				
				// Set the contents of the div
				document.getElementById("inner").innerHTML = inner;

				return value;
			}