function calculateHeights()
{
	var blockHeight = document.getElementById('blocks').scrollHeight;
	
	if(document.getElementById('verticalmenu'))
	{
		var verticalmenuHeight = document.getElementById('verticalmenu').scrollHeight;
		
		if(verticalmenuHeight > blockHeight)
			blockHeight = verticalmenuHeight;
			
		document.getElementById('verticalmenu').style.height = blockHeight + 'px';
	}
	
	if(document.getElementById('verticalmenuborder'))
		document.getElementById('verticalmenuborder').style.height = blockHeight + 'px';

	if(menuHorizontal == 1 && menuCenter == 1)
	{
		//var menuWidth = document.getElementById("horizontalmenu").childNodes[0].offsetWidth;
		var menuWidth = $j("#horizontalmenu ul.level0").outerWidth();
		$j("#horizontalmenu ul.level0").css('display', 'none');
		if(974 - menuWidth > 2)
		{
			var marginBothSides = (974 - menuWidth) / 2;
			document.getElementById('horizontalmenu').childNodes[0].style.left = marginBothSides + 'px'; 
		}
		$j("#horizontalmenu ul.level0").css('display', 'block');		
	}
	

}

$j(document).ready(
		function() { 
			setTimeout("calculateHeights()", 100);
		}
);
