function createCookie(C, E, F, D) { if (F) { var B = new Date(); B.setTime(B.getTime() + (F * 24 * 60 * 60 * 1000)); var A = "; expires=" + B.toGMTString() } else { var A = "" } document.cookie = C + "=" + E + A + "; path=/;domain=" + D.value } function SetCookie(E, B) { if (E.indexOf("&amp;") == -1) { E = E.replace("&", "&amp;") } var D = document.getElementById("menuControl1_lblEmailPref"); var A = document.getElementById("menuControl1_aTagEmail"); var C = document.getElementById("menuControl1_cookieDomain"); if (A == null) { A = document.getElementById("ctl00_menuControl1_aTagEmail") } if (D == null) { D = document.getElementById("ctl00_menuControl1_lblEmailPref") } if (C == null) { C = document.getElementById("ctl00_menuControl1_cookieDomain") } A.href = B; D.innerHTML = E; createCookie("EmailPref", E, 90, C) } function SetCookieSoc(E, C) { var B = document.getElementById("menuControl1_lblSocPref"); var A = document.getElementById("menuControl1_aTagSoc"); var D = document.getElementById("menuControl1_cookieDomain"); if (A == null) { A = document.getElementById("ctl00_menuControl1_aTagSoc") } if (B == null) { B = document.getElementById("ctl00_menuControl1_lblSocPref") } if (D == null) { D = document.getElementById("ctl00_menuControl1_cookieDomain") } A.href = C; B.innerHTML = E; createCookie("SocPref", E, 90, D) } function getCookie(A) { var B = A + "="; if (document.cookie.length > 0) { offset = document.cookie.indexOf(B); if (offset != -1) { offset += B.length; end = document.cookie.indexOf(";", offset); if (end == -1) { end = document.cookie.length } return unescape(document.cookie.substring(offset, end)) } } } function createPopup(A) { window.open(A, "", "width=450, height=500"); return true } function httpFactory() { this._factories = [function() { return new XMLHttpRequest() }, function() { return new ActiveXObject("Msxml2.XMLHTTP") }, function() { return new ActiveXObject("Microsoft.XMLHTTP") } ]; this._factory = null } var HTTP = new httpFactory(); HTTP.newRequest = function() { if (HTTP._factory != null) { return new HTTP._factory() } for (var B = 0; B < HTTP._factories.length; B++) { try { var A = HTTP._factories[B]; var C = A(); if (C != null) { HTTP._factory = A; return C } } catch (D) { continue } } HTTP._factory = function() { throw new Error("XMLHttpRequest not supported") }; HTTP._factory() }; function makeRequest(A) { var B = HTTP.newRequest(); B.open("GET", A, false); B.send(null); if (B.status == 200) { return B.responseText } else { return "Error" + B.status + ": " + B.statusText } } var pagetitle = document.title; var pageurl = window.location; delicioussubmit = '<a href="http://del.icio.us/submit?url=' + pageurl + "&title=" + pagetitle + '" target="_blank" class="delicious">del.icio.us</a>'; diggsubmit = '<a href="http://www.digg.com/submit?phase=2&url=' + pageurl + '" target="_blank" class="digg">Digg</a>'; stumblesubmit = '<a href="http://www.stumbleupon.com/submit?url=' + pageurl + "&title=" + pagetitle + '" target="_blank" class="stumbleupon">StumbleUpon</a>'; technoratisubmit = '<a href="http://www.technorati.com/faves?add=' + pageurl + '" target="_blank" class="technorati">Technorati</a>'; function toggle(B) { var A = document.getElementById(B); var C = document.getElementById("param"); if (A.id.match("web") != null) { C.value = false; $(".search ul li").addClass("inactive"); $(".search ul li:first").removeClass("inactive"); $("#search_btn_copy").val("Search the Web"); if ($(".keywords").val() != "Search for...") { $(".keywords").css("color", "#000").focus() } else { $(".keywords").css("color", "#000").val("").focus() } } else { if (A.id.match("site") != null) { C.value = true; $(".search ul li").removeClass("inactive"); $(".search ul li:first").addClass("inactive"); $("#search_btn_copy").val("Search the Site"); $(".keywords").focus(); if ($(".keywords").val() != "Search for...") { $(".keywords").css("color", "#000").focus() } else { $(".keywords").css("color", "#000").val("").focus() } } } } function toggle2(B) { var A = document.getElementById(B); var C = document.getElementById("param2"); if (A.id.match("web2") != null) { C.value = false; $(".search2 ul li").addClass("inactive"); $(".search2 ul li:first").removeClass("inactive"); $("#search_btn_copy2").val("Search the Web"); if ($(".keywords2").val() != "Search for...") { $(".keywords2").css("color", "#000").focus() } else { $(".keywords2").css("color", "#000").val("").focus() } } else { if (A.id.match("site2") != null) { C.value = true; $(".search2 ul li").removeClass("inactive"); $(".search2 ul li:first").addClass("inactive"); $("#search_btn_copy2").val("Search the Site"); $(".keywords2").focus(); if ($(".keywords2").val() != "Search for...") { $(".keywords2").css("color", "#000").focus() } else { $(".keywords2").css("color", "#000").val("").focus() } } } } function updateweather(A, C, B) { var D = "zipcode=" + A + "&unit=" + C + "&defaultZip=" + B; $.ajax({ type: "GET", url: "../weatherxml.aspx", data: D, datatype: "xml", cache: false, success: function(F) { var E = $(F).find("dnam").text(); E = E.split("(", 1); if (E == "") { E = "Enter a valid zip code. " } $(F).find("day").each(function() { var H = $(this).attr("d"); var J = $(this).attr("t"); var K = $(this).find("hi").text(); var G = $(this).find("low").text(); var I = $(this).find("icon:first").text(); if ($(".weather")) { $(".weather #weather_day" + H).replaceWith('<div id="weather_day' + H + '" class="weatherbin">' + J + '<br /><img src="/images/weather/' + I + '.png" /><br />' + G + "&deg;/" + K + "&deg;</div>") } }); $(".weather_menu").html(" - " + E + ' <img src="/images/weather/topbar/' + $(F).find("day icon:first").text() + '.png" /> ' + $(F).find("tmp").text() + "&deg;" + C.toUpperCase()); if ($(".weather")) { $(".weather #condition").replaceWith('<span id="condition"> ' + $("cc > t", F).text() + " " + $(F).find("tmp").text() + "&deg;" + C.toUpperCase() + "</span>"); $(".weather #location").replaceWith('<span id="location">' + E + "</span>"); $(".weather #weatherlinks p").replaceWith('<p><a href="http://click.freeze.com/?clname=weatherlogo&wurl=' + escape("http://www.weather.com/?prod=xoap&par=1029166254") + '" target="_blank"><img src="/images/TWClogo_64px.png" height="64" width="64" alt="weather.com" /></a><strong>featured on weather.com&reg;</strong><br /></p>'); $(F).find("link").each(function() { if ($(this).attr("pos") != "4") { $(".weather #weatherlinks p").append('<a href="http://click.freeze.com/?clname=feature' + $(this).attr("pos") + "&wurl=" + escape($(this).find("l").text()) + '" target="_blank">' + $(this).find("t").text() + "</a><br />") } }) } if (($(F).find("dnam").text() == null || $(F).find("dnam").text() == "") && F == "exceptionError") { document.getElementById("pnlWeather").innerHTML = "" } } }) } jQuery(function(B) { if (B("#top10_tabmenu")) { B("#top10_tabmenu li a:first").addClass("active"); B("#top10_tabmenu li a").click(function(C) { C.preventDefault(); B("#top10_tabmenu li a").removeClass("active"); B(this).addClass("active"); B(".top10_content").hide(); B(B(this).attr("href")).show() }) } if (B("#vibefire_one")) { B("a#vf_step_one").click(function(C) { C.preventDefault(); B("#vibefire_one").hide(); B("#vibefire_two").show() }); B("#vibefire_two input").click(function() { B("a#vf_step_two").attr("href", B(this).val()) }); B("a#vf_step_two").click(function() { B("#vibefire_two").hide(); B("#vibefire_one").show() }) } B(".hdl_block").hover(function() { B(this).css({ backgroundColor: "#efefef" }) }, function() { B(this).css({ backgroundColor: "#fff" }) }); B(".gray").bind("mouseout", function() { B(".gray .hdl_block").css("background-color", "#efefef") }); jQuery.each(B(".hdl_block_story img"), function() { if (B(this).width() < 2) { B(this).css("display", "none") } }); jQuery.each(B(".storyitem img"), function() { if (B(this).width() < 2) { B(this).css("display", "none") } }); if (location.href.match("Help.aspx") == null) { B(".searchbox").focus().css("color", "#000") } B(".searchbox2").bind("focus", function() { B(this).css("color", "#000"); if (B(this).val() == "Search for...") { B(this).val("") } }); var A = -147; B(".topbar > a").each(function() { A = A + B(this).width() }); B("#sharethispage").css("left", (A + 24) + "px"); B(".topbar a.closeshare").bind("mousedown", function() { B(".topbar a.showshare").click() }); B(".topbar a.showshare").toggle(function() { B("#sharethispage").slideDown() }, function() { B("#sharethispage").slideUp() }); if (document.all) { B("#header #nav ul li").hover(function() { B(this).addClass("hover") }, function() { B(this).removeClass("hover") }) } B("#header .infobar a.closeemail").bind("mousedown", function() { B("#header .infobar a.more").click() }); B("#header .infobar a.more").toggle(function() { if (B("#chg_soc").css("display") == "block") { B("#header .infobar a.moresoc").click() } B("#chg_email").slideDown() }, function() { B("#chg_email").slideUp() }); B("#header .infobar a.closesoc").bind("mousedown", function() { B("#header .infobar a.moresoc").click() }); B("#header .infobar a.moresoc").toggle(function() { if (B("#chg_email").css("display") == "block") { B("#header .infobar a.more").click() } B("#chg_soc").slideDown() }, function() { B("#chg_soc").slideUp() }); if (getCookie("index_weather")) { updateweather(getCookie("index_weather").match(/\d{5}/), "f", "10027") } }); function IsNumeric(B) { var D = "0123456789"; var C = true; var A; for (i = 0; i < B.length && C == true; i++) { A = B.charAt(i); if (D.indexOf(A) == -1) { C = false } } return C } function checkZipCookie(B) { var A = getCookie("myfrz_zip"); if (!A) { createCookie("myfrz_zip", B, 90, "my.freeze.com"); return B } else { return A } } function ChangeZip() { if ($("#txtZip").val().length == 5 && $("#txtZip").val() && IsNumeric($("#txtZip").val())) { updateweather($("#txtZip").val(), "f"); $("#txtZip").val("") } } function changeweather() { $(".hdl_block #weather_change").toggle() } if (typeof urlParams == "undefined") { bookmarkParams = "" } else { bookmarkParams = urlParams } function bookmarksite(C, A) { if (window.sidebar) { window.sidebar.addPanel(C, A + "?" + bookmarkParams, "") } else { if (window.opera && window.print) { var B = document.createElement("a"); B.setAttribute("href", A + "?" + bookmarkParams); B.setAttribute("title", C); B.setAttribute("rel", "sidebar"); B.click() } else { if (document.all) { window.external.AddFavorite(A + "?" + bookmarkParams, C) } } } } var fullHomePageUrl = "http://my.freeze.com/?" + bookmarkParams; function setHomePage() { if (showSetHomePage) { if (document.all) { document.write("<a href=\"javascript:history.go(0);\" onclick=\"this.style.behavior='url(#default#homepage)';this.setHomePage('" + fullHomePageUrl + "');\">"); document.write("Make This Your Homepage</a> | ") } else { if (document.getElementById) { document.write('<a href="' + fullHomePageUrl + '">Drag this link onto your Home button to make this your Home Page</a> | ') } else { if (document.layers) { document.write("") } else { document.write("") } } } } } fullSearchPageUrl = "http://search.freeze.com/Search.aspx"; function setSearchPage() { if (document.all) { document.write("<a href=\"javascript:history.go(0);\" onclick=\"this.style.behavior='url(#default#homepage)';this.setHomePage('" + fullSearchPageUrl + "');\">"); document.write("Make This Your Homepage</a>") } else { if (document.getElementById) { document.write('<a href="' + fullSearchPageUrl + '">Drag this link onto your Home button to make this your Home Page.</a>') } else { if (document.layers) { document.write("") } else { document.write("") } } } } searchRandNum = (Math.floor((Math.random() * 10) + 1)); function checkCookie() { var A = getCookie("SearchPageId"); if (A != null) { if (A == "SearchPageId=find") { searchRandNum = 5 } if (A == "SearchPageId=find_v2") { searchRandNum = 10 } } } function rndSearch() { if (searchRandNum > 0 && searchRandNum < 10) { document.write('<form name="search" action="../Search/Find.aspx" method="post">') } else { if (searchRandNum == 10) { document.write('<form name="search" action="../Search/Find.aspx" method="post">') } else { document.write('<form name="search" action="../Search/Find.aspx" method="post">') } } } function rndSearchType() { if (searchRandNum > 0 && searchRandNum < 10) { document.write('<input name="type" id="type" type="hidden" value="t2v10" />') } else { if (searchRandNum == 10) { document.write('<input name="type" id="type" type="hidden" value="t2v10" />') } else { document.write('<input name="type" id="type" type="hidden" value="t2v10" />') } } };