function adjustFontSize(obj) {
    var topNavHeight = "32";
    var size = "12";
    var textresized = 1;
    if (obj == null) {
        obj = get_cookie("EQTextResize");
        textresized = 0;
    }
    if (obj != null) {
        if (obj == "large_a") {
            size = "16";
            topNavHeight = "65";
        }
        else if (obj == "medium_a") {
            size = "14";
            topNavHeight = "50";
        }
        if (textresized == 1) {
            delete_cookie('EQTextResize');
            set_cookie('EQTextResize', obj, null, "/");
        }
        var alt = "";
        $("#text_size img").each(function() {
			alt = $(this).attr("alt");
            if ($(this).attr("id") == obj) {
				$(this).parent("a").html('<img src="Library/images/' + $(this).attr("id") + '_on.png" id="' + $(this).attr("id") + '" alt="'+ alt + '" title="'+ alt + '" width="16" height="16" />').pngFix();
                $(this).css("cursor", "default");
            }
            else {
				$(this).parent("a").html('<img src="Library/images/' + $(this).attr("id") + '_off.png" id="' + $(this).attr("id") + '" alt="'+ alt + '" title="'+ alt + '" width="16" height="16" />').pngFix();
                $(this).css("cursor", "pointer");
            }
        });
       
    }
    
    $("body").css("font-size", size + "px");
    $(".topNavPOTCItem").css("height", topNavHeight + "px");


}


function set_cookie(name, value, days, path) {
    var cookie_string = name + "=" + escape(value);

    if (days != null) {
        var expires = new Date(days);
        cookie_string += "; expires=" + expires.toGMTString();
    }

    if (path)
        cookie_string += "; path=" + escape(path);

    document.cookie = cookie_string;
}


function get_cookie(name) {
    var nameEQ = name + "=";
    var ca = document.cookie.split(';');
    for (var i = 0; i < ca.length; i++) {
        var c = ca[i];
        while (c.charAt(0) == ' ') c = c.substring(1, c.length);
        if (c.indexOf(nameEQ) == 0) return unescape(c.substring(nameEQ.length, c.length));
    }
    return null;
}


function delete_cookie(cookie_name) {
    var cookie_date = new Date();  // current date & time
    cookie_date.setTime(cookie_date.getTime() - 1);
    document.cookie = cookie_name += "=; expires=" + cookie_date.toGMTString();
}
