﻿function AutoColumnsHeight() {   
    var leftCol = window.document.getElementById('leftcolumn');
    var rightCol = window.document.getElementById('rightcolumn');
    if (rightCol == null) {
        var centerCol = window.document.getElementById('content2');   
        var hCenterCol = centerCol.offsetHeight;
        var hLeftCol = leftCol.offsetHeight;
        var maxHeight = Math.max(hCenterCol, hLeftCol);       
        centerCol.style.height = maxHeight + 'px';
        leftCol.style.height = maxHeight + 'px';         
     }
     else {
        var centerCol = window.document.getElementById('content');   
        var hCenterCol = centerCol.offsetHeight;
        var hLeftCol = leftCol.offsetHeight;
        var hRightCol = rightCol.offsetHeight;
        var maxHeight = Math.max(hCenterCol, Math.max(hLeftCol, hRightCol));    
        centerCol.style.height = maxHeight + 'px';
        leftCol.style.height = maxHeight + 'px';
        rightCol.style.height = maxHeight + 'px';
    }
    window.document.getElementById('footer').style.visibility = 'inherit';

    var hid1 = window.document.getElementById('Hidden1');
    if (hid1 != null) {
        var mnf = window.document.getElementById('headfon');
        if (hid1.value == 116) {
            mnf.className = "fon1";
            var h1 = window.document.getElementById('ctl00_CompanyMenu');
            h1.className = "CompanyClassUp";
        }
        if (hid1.value == 131) {
            mnf.className = "fon2";
            var h1 = window.document.getElementById('ctl00_ExpoMenu');
            h1.className = "ExpoClassUp";
        }
        if (hid1.value == 203) {
            mnf.className = "fon3";
            var h1 = window.document.getElementById('ctl00_StendMenu');
            h1.className = "StendClassUp";
        }
        if (hid1.value == 204) {
            mnf.className = "fon4";
            var h1 = window.document.getElementById('ctl00_ReclamaMenu');
            h1.className = "ReclamaClassUp";
        }
        if (hid1.value == 225) {
            mnf.className = "fon5";
            var h1 = window.document.getElementById('ctl00_RestoranMenu');
            h1.className = "RestoranClassUp";
        }
    }
    else {
        var mnf = window.document.getElementById('headfon')
     mnf.className = "fon1"; }
   
}
window.onload = function() { AutoColumnsHeight(); }
