function max(a, b)
{
    if (a > b)
        return a;
    return b;
}

function FitContent()
{
    var height = 0;
    height = max(height, parseInt($('#content').css('height')));
    height = max(height, parseInt($('#left').css('height')));
    
    if (height > parseInt($("#content").css('height')))
        $('#content').css('height', height + 'px');

    return;

    $(window).resize(
        function()
        {
            var height = 0;
            height = max(height, parseInt($('#content').css('height')));
            height = max(height, parseInt($('#left').css('height')));
            height = max(height, parseInt($('#right').css('height')));
                
            $('#left').css('height', height + 'px');
            $('#right').css('height', height + 'px');
            $('#content').css('height', height + 'px');
            $('iframe').css('height', height + 'px');
        });
    $("#content").resize(
        function()
        {
            alert("change!");
            var height = 0;
            height = max(height, parseInt($('#content').css('height')));
            height = max(height, parseInt($('#left').css('height')));
            height = max(height, parseInt($('#right').css('height')));
                
            $('#left').css('height', height + 'px');
            $('#right').css('height', height + 'px');
            $('#content').css('height', height + 'px');
            $('iframe').css('height', height + 'px');    
        });
}


