// JavaScript Document



function heights(){
	var leftCol = document.getElementById('leftCol');
	var bottomLeft = document.getElementById('bottomLeft');
	var bottomMiddle = document.getElementById('bottomMiddle');
	var bottomRight = document.getElementById('bottomRight');
	var topBox = document.getElementById('topBox');
	var rightCol = document.getElementById('rightCol');
	
	bottomLeft.style.height = "auto";
	bottomMiddle.style.height = "auto";
	bottomRight.style.height = "auto";
	rightCol.style.height = "auto";
	
	var h = Math.max(bottomLeft.offsetHeight, bottomMiddle.offsetHeight);
	h = Math.max(h, bottomRight.offsetHeight);
	
	if(bottomLeft.offsetHeight != h){
		bottomLeft.style.height=h+'px';
	}
	if(bottomMiddle.offsetHeight != h){
		bottomMiddle.style.height=(h)+'px';
	}
	if(bottomRight.offsetHeight != h){
		bottomRight.style.height=(h)+'px';
	}

    h = Math.max(leftCol.offsetHeight, rightCol.offsetHeight);
	
	if (rightCol.offsetHeight<=h){
		rightCol.style.height=(h-15)+'px';
	}
	
	
	if (leftCol.offsetHeight<=h){
		var setHeight = h - topBox.offsetHeight - 20;
		bottomLeft.style.height = setHeight+'px';
		bottomMiddle.style.height = setHeight+'px';
		bottomRight.style.height = setHeight+'px';
	}
	
}

function heightsGeneral(){
	var leftCol = document.getElementById('leftCol');
	var rightCol = document.getElementById('rightCol');
	var submenu = document.getElementById('submenu');
	
	leftCol.style.height = "auto";
	rightCol.style.height = "auto";
	submenu.style.height = "auto";
	
	var h = Math.max(leftCol.offsetHeight, rightCol.offsetHeight);
	h = Math.max(h, submenu.offsetHeight);
	
	if (rightCol.offsetHeight<=h){
		rightCol.style.height=(h-15)+'px';
	}
	
	if (submenu.offsetHeight<=h){
		submenu.style.height=h+'px';
	}
}

function copyright(){
	
	document.write("&copy; Copyright 2in10 Ltd, ");
	var currentTime = new Date();
	var year = currentTime.getFullYear();
	document.write(year);

}