﻿(function(a7, aG) { var aN = "none", aP = "click", ap = "LoadedContent", a5 = false, aL = "resize.", aU = "y", aO = "auto", a3 = true, aq = "nofollow", aS = "on", aV = "x"; function a4(b, d) { b = b ? ' id="' + aY + b + '"' : ""; d = d ? ' style="' + d + '"' : ""; return a7("<div" + b + d + "/>") } function aT(d, c) { c = c === aV ? aW.width() : aW.height(); return typeof d === "string" ? Math.round(d.match(/%/) ? c / 100 * parseInt(d, 10) : parseInt(d, 10)) : d } function am(a) { a = a7.isFunction(a) ? a.call(a1) : a; return a8.photo || a.match(/\.(gif|png|jpg|jpeg|bmp)(?:\?([^#]*))?(?:#(\.*))?$/i) } function aH() { for (var a in a8) { if (a7.isFunction(a8[a]) && a.substring(0, 2) !== aS) { a8[a] = a8[a].call(a1) } } a8.rel = a8.rel || a1.rel || aq; a8.href = a8.href || a7(a1).attr("href"); a8.title = a8.title || a1.title } function aF(b) { a1 = b; a8 = a7.extend({}, a7(a1).data(aR)); aH(); if (a8.rel !== aq) { a0 = a7("." + aw).filter(function() { return (a7(this).data(aR).rel || this.rel) === a8.rel }); a2 = a0.index(a1); if (a2 === -1) { a0 = a0.add(a1); a2 = a0.length - 1 } } else { a0 = a7(a1); a2 = 0 } if (!aM) { aM = ay = a3; al = a1; try { al.blur() } catch (a) { } a7.event.trigger(ac); a8.onOpen && a8.onOpen.call(a1); aK.css({ opacity: +a8.opacity, cursor: a8.overlayClose ? "pointer" : aO }).show(); a8.w = aT(a8.initialWidth, aV); a8.h = aT(a8.initialHeight, aU); a6.position(0); ak && aW.bind(aL + ao + " scroll." + ao, function() { aK.css({ width: aW.width(), height: aW.height(), top: aW.scrollTop(), left: aW.scrollLeft() }) }).trigger("scroll." + ao) } aj.add(av).add(au).add(aJ).add(ai).hide(); ah.html(a8.close).show(); a6.slideshow(); a6.load() } var aa = { transition: "elastic", speed: 300, width: a5, initialWidth: "600", innerWidth: a5, maxWidth: a5, height: a5, initialHeight: "450", innerHeight: a5, maxHeight: a5, scalePhotos: a3, scrolling: a3, inline: a5, html: a5, iframe: a5, photo: a5, href: a5, title: a5, rel: a5, opacity: 0.9, preloading: a3, current: "image {current} of {total}", previous: "previous", next: "next", close: "close", open: a5, loop: a3, slideshow: a5, slideshowAuto: a3, slideshowSpeed: 2500, slideshowStart: "start slideshow", slideshowStop: "stop slideshow", onOpen: a5, onLoad: a5, onComplete: a5, onCleanup: a5, onClosed: a5, overlayClose: a3, escKey: a3, arrowKey: a3 }, aR = "colorbox", aY = "cbox", ac = aY + "_open", an = aY + "_load", ag = aY + "_complete", af = aY + "_cleanup", aI = aY + "_closed", ax = a7.browser.msie && !a7.support.opacity, ak = ax && a7.browser.version < 7, ao = aY + "_IE6", aK, aZ, az, aQ, ae, ad, aE, a9, a0, aW, aX, at, ar, ai, aj, aJ, au, av, ah, aB, aA, aD, aC, a1, al, a2, a8, aM, ay, a6, aw = aY + "Element"; a6 = a7.fn[aR] = a7[aR] = function(f, e) { var b = this; if (!b[0] && b.selector) { return b } f = f || {}; if (e) { f.onComplete = e } if (!b[0] || b.selector === undefined) { b = a7("<a/>"); f.open = a3 } b.each(function() { a7(this).data(aR, a7.extend({}, a7(this).data(aR) || aa, f)).addClass(aw) }); f.open && aF(b[0]); return b }; a6.init = function() { var a = "hover"; aW = a7(aG); aZ = a4().attr({ id: aR, "class": ax ? aY + "IE" : "" }); aK = a4("Overlay", ak ? "position:absolute" : "").hide(); az = a4("Wrapper"); aQ = a4("Content").append(aX = a4(ap, "width:0; height:0"), ar = a4("LoadingOverlay").add(a4("LoadingGraphic")), ai = a4("Title"), aj = a4("Current"), au = a4("Next"), av = a4("Previous"), aJ = a4("Slideshow"), ah = a4("Close")); az.append(a4().append(a4("TopLeft"), ae = a4("TopCenter"), a4("TopRight")), a4().append(ad = a4("MiddleLeft"), aQ, aE = a4("MiddleRight")), a4().append(a4("BottomLeft"), a9 = a4("BottomCenter"), a4("BottomRight"))).children().children().css({ "float": "left" }); at = a4(a5, "position:absolute; width:9999px; visibility:hidden; display:none"); a7("body").prepend(aK, aZ.append(az, at)); aQ.children().hover(function() { a7(this).addClass(a) }, function() { a7(this).removeClass(a) }).addClass(a); aB = ae.height() + a9.height() + aQ.outerHeight(a3) - aQ.height(); aA = ad.width() + aE.width() + aQ.outerWidth(a3) - aQ.width(); aD = aX.outerHeight(a3); aC = aX.outerWidth(a3); aZ.css({ "padding-bottom": aB, "padding-right": aA }).hide(); au.click(a6.next); av.click(a6.prev); ah.click(a6.close); aQ.children().removeClass(a); a7("." + aw).live(aP, function(b) { if (b.button !== 0 && typeof b.button !== "undefined" || b.ctrlKey || b.shiftKey || b.altKey) { return a3 } else { aF(this); return a5 } }); aK.click(function() { a8.overlayClose && a6.close() }); a7(document).bind("keydown", function(c) { if (aM && a8.escKey && c.keyCode === 27) { c.preventDefault(); a6.close() } if (aM && a8.arrowKey && !ay && a0[1]) { if (c.keyCode === 37 && (a2 || a8.loop)) { c.preventDefault(); av.click() } else { if (c.keyCode === 39 && (a2 < a0.length - 1 || a8.loop)) { c.preventDefault(); au.click() } } } }) }; a6.remove = function() { aZ.add(aK).remove(); a7("." + aw).die(aP).removeData(aR).removeClass(aw) }; a6.position = function(k, a) { function m(b) { ae[0].style.width = a9[0].style.width = aQ[0].style.width = b.style.width; ar[0].style.height = ar[1].style.height = aQ[0].style.height = ad[0].style.height = aE[0].style.height = b.style.height } var l, d = Math.max(aW.height() - a8.h - aD - aB, 0) / 2 + aW.scrollTop(), j = Math.max(aW.width() - a8.w - aC - aA, 0) / 2 + aW.scrollLeft(); l = aZ.width() === a8.w + aC && aZ.height() === a8.h + aD ? 0 : k; az[0].style.width = az[0].style.height = "9999px"; aZ.dequeue().animate({ width: a8.w + aC, height: a8.h + aD, top: d, left: j }, { duration: l, complete: function() { m(this); ay = a5; az[0].style.width = a8.w + aC + aA + "px"; az[0].style.height = a8.h + aD + aB + "px"; a && a() }, step: function() { m(this) } }) }; a6.resize = function(a) { if (aM) { a = a || {}; if (a.width) { a8.w = aT(a.width, aV) - aC - aA } if (a.innerWidth) { a8.w = aT(a.innerWidth, aV) } aX.css({ width: a8.w }); if (a.height) { a8.h = aT(a.height, aU) - aD - aB } if (a.innerHeight) { a8.h = aT(a.innerHeight, aU) } if (!a.innerHeight && !a.height) { a = aX.wrapInner("<div style='overflow:auto'></div>").children(); a8.h = a.height(); a.replaceWith(a.children()) } aX.css({ height: a8.h }); a6.position(a8.transition === aN ? 0 : a8.speed) } }; a6.prep = function(e) { var c = "hidden"; function g(f) { var m, j, h, p, l = a0.length, k = a8.loop; a6.position(f, function() { function d() { ax && aZ[0].style.removeAttribute("filter") } if (aM) { ax && b && aX.fadeIn(100); a8.iframe && a7("<iframe frameborder=0" + (a8.scrolling ? "" : " scrolling='no'") + (ax ? " allowtransparency='true'" : "") + "/>").attr({ src: a8.href, name: (new Date).getTime() }).appendTo(aX); aX.show(); ai.show().html(a8.title); if (l > 1) { aj.html(a8.current.replace(/\{current\}/, a2 + 1).replace(/\{total\}/, l)).show(); au[k || a2 < l - 1 ? "show" : "hide"]().html(a8.next); av[k || a2 ? "show" : "hide"]().html(a8.previous); m = a2 ? a0[a2 - 1] : a0[l - 1]; h = a2 < l - 1 ? a0[a2 + 1] : a0[0]; if (a8.slideshow) { aJ.show(); a2 === l - 1 && !k && aZ.is("." + aY + "Slideshow_on") && aJ.click() } if (a8.preloading) { p = a7(h).data(aR).href || h.href; j = a7(m).data(aR).href || m.href; if (am(p)) { a7("<img/>")[0].src = p } if (am(j)) { a7("<img/>")[0].src = j } } } ar.hide(); a8.transition === "fade" ? aZ.fadeTo(a, 1, function() { d() }) : d(); aW.bind(aL + aY, function() { a6.position(0) }); a7.event.trigger(ag); a8.onComplete && a8.onComplete.call(a1) } }) } if (aM) { var b, a = a8.transition === aN ? 0 : a8.speed; aW.unbind(aL + aY); aX.remove(); aX = a4(ap).html(e); aX.hide().appendTo(at.show()).css({ width: function() { a8.w = a8.w || aX.width(); a8.w = a8.mw && a8.mw < a8.w ? a8.mw : a8.w; return a8.w } (), overflow: a8.scrolling ? aO : c }).css({ height: function() { a8.h = a8.h || aX.height(); a8.h = a8.mh && a8.mh < a8.h ? a8.mh : a8.h; return a8.h } () }).prependTo(aQ); at.hide(); a7("#" + aY + "Photo").css({ cssFloat: aN }); ak && a7("select").not(aZ.find("select")).filter(function() { return this.style.visibility !== c }).css({ visibility: c }).one(af, function() { this.style.visibility = "inherit" }); a8.transition === "fade" ? aZ.fadeTo(a, 0, function() { g(0) }) : g(a) } }; a6.load = function() { var b, e, c, a = a6.prep; ay = a3; a1 = a0[a2]; a8 = a7.extend({}, a7(a1).data(aR)); aH(); a7.event.trigger(an); a8.onLoad && a8.onLoad.call(a1); a8.h = a8.height ? aT(a8.height, aU) - aD - aB : a8.innerHeight && aT(a8.innerHeight, aU); a8.w = a8.width ? aT(a8.width, aV) - aC - aA : a8.innerWidth && aT(a8.innerWidth, aV); a8.mw = a8.w; a8.mh = a8.h; if (a8.maxWidth) { a8.mw = aT(a8.maxWidth, aV) - aC - aA; a8.mw = a8.w && a8.w < a8.mw ? a8.w : a8.mw } if (a8.maxHeight) { a8.mh = aT(a8.maxHeight, aU) - aD - aB; a8.mh = a8.h && a8.h < a8.mh ? a8.h : a8.mh } b = a8.href; ar.show(); if (a8.inline) { a4("InlineTemp").hide().insertBefore(a7(b)[0]).bind(an + " " + af, function() { a7(this).replaceWith(aX.children()) }); a(a7(b)) } else { if (a8.iframe) { a(" ") } else { if (a8.html) { a(a8.html) } else { if (am(b)) { e = new Image; e.onload = function() { var d; e.onload = null; e.id = aY + "Photo"; a7(e).css({ margin: aO, border: aN, display: "block", cssFloat: "left" }); if (a8.scalePhotos) { c = function() { e.height -= e.height * d; e.width -= e.width * d }; if (a8.mw && e.width > a8.mw) { d = (e.width - a8.mw) / e.width; c() } if (a8.mh && e.height > a8.mh) { d = (e.height - a8.mh) / e.height; c() } } if (a8.h) { e.style.marginTop = Math.max(a8.h - e.height, 0) / 2 + "px" } setTimeout(function() { a(e) }, 1); a0[1] && (a2 < a0.length - 1 || a8.loop) && a7(e).css({ cursor: "pointer" }).click(a6.next); if (ax) { e.style.msInterpolationMode = "bicubic" } }; e.src = b } else { a4().appendTo(at).load(b, function(g, f, d) { a(f === "error" ? "Request unsuccessful: " + d.statusText : this) }) } } } } }; a6.next = function() { if (!ay) { a2 = a2 < a0.length - 1 ? a2 + 1 : 0; a6.load() } }; a6.prev = function() { if (!ay) { a2 = a2 ? a2 - 1 : a0.length - 1; a6.load() } }; a6.slideshow = function() { function c() { aJ.text(a8.slideshowStop).bind(ag, function() { h = setTimeout(a6.next, a8.slideshowSpeed) }).bind(an, function() { clearTimeout(h) }).one(aP, function() { g() }); aZ.removeClass(a + "off").addClass(a + aS) } var g, h, a = aY + "Slideshow_"; aJ.bind(aI, function() { aJ.unbind(); clearTimeout(h); aZ.removeClass(a + "off " + a + aS) }); g = function() { clearTimeout(h); aJ.text(a8.slideshowStart).unbind(ag + " " + an).one(aP, function() { c(); h = setTimeout(a6.next, a8.slideshowSpeed) }); aZ.removeClass(a + aS).addClass(a + "off") }; if (a8.slideshow && a0[1]) { a8.slideshowAuto ? c() : g() } }; a6.close = function() { if (aM) { aM = a5; a7.event.trigger(af); a8.onCleanup && a8.onCleanup.call(a1); aW.unbind("." + aY + " ." + ao); aK.fadeTo("fast", 0); aZ.stop().fadeTo("fast", 0, function() { aZ.find("iframe").attr("src", "about:blank"); aX.remove(); aZ.add(aK).css({ opacity: 1, cursor: aO }).hide(); try { al.focus() } catch (a) { } setTimeout(function() { a7.event.trigger(aI); a8.onClosed && a8.onClosed.call(a1) }, 1) }) } }; a6.element = function() { return a7(a1) }; a6.settings = aa; a7(a6.init) })(jQuery, this); scriptobjects = document.getElementsByTagName("script"); var regExFile = /sio.panel-1.1/; var sioUrl; for (i = 0; i < scriptobjects.length; i++) { if (scriptobjects[i].src.match(regExFile)) { var regExUrl = /^http:\/\/[a-z0-9\.\:]+\//; foundUrl = scriptobjects[i].src.match(regExUrl); if (foundUrl != null && foundUrl.length > 0) { sioUrl = foundUrl[0].substr(0, foundUrl[0].length - 1); break } } } jQuery(document).ready(function(g) { g.cookie = function(F, y, v) { if (typeof y != "undefined") { v = v || {}; if (y === null) { y = ""; v.expires = -1 } var C = ""; if (v.expires && (typeof v.expires == "number" || v.expires.toUTCString)) { var B; if (typeof v.expires == "number") { B = new Date(); B.setTime(B.getTime() + (v.expires * 24 * 60 * 60 * 1000)) } else { B = v.expires } C = "; expires=" + B.toUTCString() } var w = v.path ? "; path=" + (v.path) : ""; var A = v.domain ? "; domain=" + (v.domain) : ""; var G = v.secure ? "; secure" : ""; document.cookie = [F, "=", encodeURIComponent(y), C, w, A, G].join("") } else { var D = null; if (document.cookie && document.cookie != "") { var x = document.cookie.split(";"); for (var z = 0; z < x.length; z++) { var E = jQuery.trim(x[z]); if (E.substring(0, F.length + 1) == (F + "=")) { D = decodeURIComponent(E.substring(F.length + 1)); break } } } return D } }; g.ajaxSettings.traditional = true; var s; var p = ["Facebook", "Twitter", "Email"]; var o, c, j, m, k, r, u, d, n; var f = false; var t; var h; var b = 600; var l = 600; var t = "Top"; var a = false; if (typeof (window.sioLoadCbFunc) == "undefined") { var q = null } else { var q = window.sioLoadCbFunc } var e = function(v, x) { var w = g("meta[property=" + v + "]").attr("content"); if (typeof (w) == "undefined") { return x } return w }; sioGetUrlWithoutPairs = function(C, B) { var v = C.split("?"); var z = v[0]; var D = ""; for (var y = 1; y < v.length; y++) { D += v[y] } var x = ""; var E = false; if (D != null && D.length != 0) { var A = D.split("&"); for (var y = 0; y < A.length; y++) { keyValuePair = A[y]; for (var w = 0; w < B.length; w++) { if (keyValuePair.split("=")[0] == B[w]) { E = true; break } } if (!E) { if (x.length == 0) { x = keyValuePair } else { x = x + "&" + keyValuePair } E = false } } if (x != "") { z = z + "?" + x } } return z }, sioLoadFb = function(w, v) { g("head").append('<div id="fb-root"></div>'); var x = document.createElement("script"); x.async = true; x.src = document.location.protocol + "//connect.facebook.net/" + v + "/all.js"; g("#fb-root").append(x); g(".sioFbLike").each(function() { g(this).html("<fb:like></fb:like>") }); window.fbAsyncInit = function() { FB.init({ appId: w, status: true, cookie: true, xfbml: true }) } }, sioStoreVisitId = function(w, v) { if (v != null) { var x = new Date(); x.setTime(x.getTime() + (0.5 * 60 * 1000)); g.cookie("SIO_VRec_" + w, v, { expires: 90 }) } }, sioGetVisitId = function(v) { g.cookie("SIO_VRec_" + v) }, sioUpdateButtonLinksWithVisit = function(v) { g(".sioSharePanel").each(function() { var y = g(this).attr("href"); var x = ["vid"]; var w = sioGetUrlWithoutPairs(y, x) + "&vid=" + v; g(this).attr("href", w) }) }, sioQueryStringValueFromLink = function(w, y) { var A = ""; var z = w.split("?"); var x = ""; for (var v = 1; v < z.length; v++) { x += z[v] } if (x != null && x.length != 0) { for (var v = 0; v < x.split("&").length; v++) { keyValuePair = x.split("&")[v]; if (keyValuePair.split("=")[0] == y) { A = keyValuePair.split("=")[1]; break } } } return A }, sioAddLink = function(v, y) { var x = sioQueryStringValueFromLink(y, "url"); var w = jQuery.inArray(x, v); if (w == -1) { v.push(x) } }, sioGetCanonicalUrl = function() { var w = g("head > link[rel=canonical").attr("href"); if (w == null || w == "undefined") { var v = ["siorid", "pdata1", "pdata2", "pdata3", "pdata4", "utm_source", "utm_source", "utm_medium", "utm_term", "utm_campaign"]; w = sioGetUrlWithoutPairs(location.href, v) } return w }, sioShowSlider = function() { var v = (t == "Top") ? { marginTop: "0px"} : { marginBottom: "0px" }; g("#sio" + t + "SliderBottom").css("border-bottom", "0"); g("#sio" + t + "SliderContentWraper").fadeIn(450); g("#sio" + t + "Slider").animate(v, 500); g("#sioTabImage").html('<div id="sio' + t + 'SliderCloseImg"></div>') }, sioHideSlider = function() { var v = (t == "Top") ? { marginTop: "-135px"} : { marginBottom: "-135px" }; g("#sio" + t + "Slider").animate(v, 500); g("#sio" + t + "SliderContentWraper").fadeOut(450, function() { if (t == "Btm") { g("#sio" + t + "SliderBottom").css("border-bottom", "2px solid #139dd9") } if (navigator.appName == "Microsoft Internet Explorer") { g("#sio" + t + "SliderContentWraper").css("height", "130px") } }); g("#sioTabImage").html('<div id="sio' + t + 'SliderOpenImg"></div>') }, sioSetUpVisitPanel = function() { var v = sioQueryStringValueFromLink(location.href, "siorid"); if (v != null && v.length != 0) { g.getJSON(sioUrl + "/ReferralVisit/GetVisitorMsg?callback=?", { refCode: v, canUrl: encodeURIComponent(d) }, function(w) { if (w.status == "OK") { sioStoreVisitId(w.buttonGuid, w.visitId); sioUpdateButtonLinksWithVisit(w.visitId); if (t == "Top") { g("body").append('<div id="sioSliderWrap"><div id="sioTopSlider"><div id="sioTopSliderTab"><div id="sioTopOpenCloseWrap"><a href="#" id="sioTabImage"></a></div></div><div id="sioTopSliderBottom"></div><div id="sioTopSliderContentWraper"><div id="sioSliderContent"></div></div></div></div>') } else { g("body").append('<div id="sioSliderWrap"><div id="sioBtmSlider"><div id="sioBtmSliderTab"><div id="sioBtmOpenCloseWrap"><a href="#" id="sioTabImage"></a></div></div><div id="sioBtmSliderBottom"></div><div id="sioBtmSliderContentWraper"><div id="sioSliderContent"></div></div></div></div>') } g("#sioSliderContent").html('<div id="sioSliderCampaignSection"></div>'); g("#sioSliderCampaignSection").html(w.sliderCampaignContent); g("#sioSliderCampaignSection .sioSharePanel").each(function() { g(this).sioSetUpButtonLink() }); g(".sioCampaignLink").each(function() { g(this).attr("target", "_blank"); g(this).click(function(x) { g.post(sioUrl + "/cth/" + g(this).attr("rel")) }) }); sioShowSlider(); g("#sioTabImage").toggle(sioHideSlider, sioShowSlider) } }) } }, sioSetUpColorBox = function(v) { v.colorbox({ iframe: true, speed: 250, innerWidth: l, innerHeight: b, href: g(this).attr("href"), onLoad: function() { window.scrollTo(0, 0); if (q) { q(g(this).attr("id")) } } }) }, sioLoadColorBox = function(v) { if (!h) { g("head").append('<link rel="stylesheet" type="text/css" href="' + sioUrl + '/js/jq/jquery.colorbox.css" />'); f = true; g(".sioSharePanel").each(function() { sioSetUpColorBox(g(this)) }); if (v) { v() } } else { g(".sioSharePanel").each(function() { g(this).click(function(w) { if (q) { q(g(this).attr("id")) } }) }); if (v) { v() } } }, sioLoadPopularContent = function() { var v = g(".sioPopularContent").length; if (v > 0) { g.getJSON(sioUrl + "/Widget/PopularContent?callback=?", { bguid: o }, function(w) { if (w.status == "OK" && w.links.length != 0) { g(".sioPopularContent").each(function() { g(this).hasClass("sioPcNumbered") ? numbered = true : numbered = false; g(this).hasClass("sioPcImages") ? images = true : images = false; g(this).sioSetUpPopularContent(w, numbered, images) }) } }) } }; g.fn.sioSetUpButtonLink = function() { var x = g(this); if (x == null) { return } var A = ""; if (h) { x.attr("target", "_blank") } var z = x.attr("href"); if (z == null || z.length == 0) { if (o) { A = o } else { return } var B = x.attr("title"); if (B == "") { B = n } z = sioUrl + "/share?bid=" + o; z += "&lang=" + r; z += "&type=" + u; z += "&url=" + encodeURIComponent(d) + "&title=" + encodeURIComponent(B); if (c != null) { z += "&image=" + encodeURIComponent(c) } if (j != null) { z += "&video=" + encodeURIComponent(j) } } else { A = sioQueryStringValueFromLink(z, "bid"); var B = sioQueryStringValueFromLink(z, "desc"); var y = sioQueryStringValueFromLink(z, "media"); var w = ["desc", "media"]; z = sioGetUrlWithoutPairs(z, w); z += "&title=" + B; if (y != "") { z += "&type=" + y } } var v = sioGetVisitId(A); if (v != null && v.length != 0) { z += "&vid=" + v } x.attr("href", z); if (f) { sioSetUpColorBox(x) } }; g.fn.sioSetUpButtonLook = function(L) { var D = g(this); var y = false; var z = false; var A = "Shareiton_16.png"; var H = false; var M = false; var J; var C; if (D.hasClass("bType_h_small")) { z = true; J = 170; C = 22 } else { if (D.hasClass("bType_h_small_aggr_count")) { M = true; z = true; J = 170; C = 70; H = true } else { if (D.hasClass("bType_h_large")) { J = 120; C = 60 } else { if (D.hasClass("bType_h_large_count")) { J = 290; C = 60; H = true } else { if (D.hasClass("bType_v_large")) { y = true; J = 60; C = 130; A = "Shareiton_8_short.png" } else { if (D.hasClass("bType_v_large_count")) { y = true; J = 100; C = 140; H = true } else { return } } } } } } var v = sioUrl + "/Site-Media/Images/SocialNet/s/allforbutton"; var K = sioUrl + "/Site-Media/Images/SioIcons/"; var A = K + r + "/" + A; var G = 16; var x = 18; if (!z) { G = 32; x = 35 } if (H) { sioAddLink(L, D.attr("href")) } var F = ""; var B; var E = 5; var I = D.css("background-color"); if (y) { F = '<table style="direction:ltr;" cellpadding="2" cellspacing="0"><tr><td><img style="border:0px" src="' + A + '"></td></tr>'; for (B = 0; B < p.length; B++) { F += "<tr><td>"; F += '<table cellpadding="0" cellspacing="0" style="background-color:' + I + ';">'; F += '<tr><td style="width:' + G + "px;height:" + G + "px;display:block;background-image:url(" + v + G + "-1.0.png);background-position:-" + E + 'px -5px;"  alt="' + p[B] + '"></td>'; if (H) { F += '<td class="sioVisitCount sioVC_' + p[B] + '"></td>' } F += "</tr></table></td></tr>"; E = E + x } F += "</table>"; D.html('<div style="width:' + J + "px;height:" + C + "px;margin:0 auto;background-color:" + I + ';">' + F + "</div>") } else { F = '<table style="direction:ltr;" cellpadding="3" cellspacing="0">'; if (z) { F += '<tr><td><img style="border:0px;margin-right:5px" src="' + A + '"></td>' } else { F += '<tr><td colspan="' + p.length + '"><img style="border:0px;margin-right:5px" src="' + A + '"></td></tr><tr>' } for (B = 0; B < p.length; B++) { F += "<td>"; F += '<table cellpadding="0" cellspacing="0" style="background-color:' + I + ';">'; F += '<tr><td style="width:' + G + "px;height:" + G + "px;background-image:url(" + v + G + "-1.0.png);background-position:-" + E + 'px -5px;"  alt="' + p[B] + '"></td>'; if (H && !M) { F += '<td class="sioVisitCount sioVC_' + p[B] + '"></td>' } F += "</tr></table></td>"; E = E + x } F += "</tr></table>"; D.html('<div style="width:' + J + "px;height:" + C + "px;margin:0 auto;background-color:" + I + '">' + (M ? '<div class="sioAggregateVisitCount"></div>' : "") + F + "</div>") } }; g.fn.sioUpdateButtonCounts = function(w) { var A = g(this); if (w != null) { if (A.hasClass("bType_h_small_aggr_count") || A.hasClass("bType_v_large_count") || A.hasClass("bType_h_large_count") || A.hasClass("bType_h_large_aggr_count")) { url = sioQueryStringValueFromLink(A.attr("href"), "url"); var E = w[url]; var v = A.css("color"); var x = "0px"; if (A.hasClass("bType_h_small_aggr_count")) { var y = A.find(".sioAggregateVisitCount")[0]; var F = 0; var B = 0; for (var z = 0; z < p.length; z++) { F += E.sends[p[z]]; B += E.visits[p[z]] } if (F > 1 && B > 1) { g(y).html(w.messageHave.replace("{visits}", B).replace("{sends}", F)) } else { g(y).html(w.messageDontHave); x = "15px" } g(y).css({ direction: w.textDirection, color: v, "padding-top": x }) } else { for (var z = 0; z < p.length; z++) { var C = E.visits[p[z]]; var D = 12; if (C == 0) { C = "Be the<br/> First"; D = 10 } if (C >= 1000000) { C = "Over a<br/> Million!"; D = 10 } var y = A.find(".sioVC_" + p[z])[0]; g(y).html(C); g(y).css({ color: v, "font-size": D }) } } } } }; g.fn.sioSetUpPopularContent = function(B, E, F) { var y = g(this); var C = '<table cellspacing="0" cellpadding="0" class="sioPcTable">'; var x = (F ? 50 : 75); var D = ""; var H = (F ? 5 : 8); for (var A = 0; A < B.links.length; A++) { var G = B.links[A]; C += '<tr class="sioPcRow">'; if (E) { C += '<td class="sioPcColNumber">' + (A + 1) + "</td>" } if (F) { C += '<td class="sioPcColImage"><img class="sioPcImage" src="' + G.ImageUrl + '" /></td>' } if (G.ContentTitle.length > x) { D = "..." } C += '<td class="sioPcColLink"><a href="' + G.Link + '">' + G.ContentTitle.substr(0, x) + D + "</a><br/>"; var w = 0; for (var z = 0; z < B.people.length && w < H; z++) { var v = B.people[z]; if (v.OrderIndex == G.OrderIndex) { w++; if (v.ExternalPlatformId == 1) { C += '<img style="margin:1px" src="http://graph.facebook.com/' + v.ExternalPlatformUserId + '/picture?type=square" width="32" height="32" alt="' + v.CallingName + '" />' } else { C += '<img style="margin:1px" src="http://api.twitter.com/1/users/profile_image/' + v.ExternalPlatformUserId + '.json?size=normal" width="32" height="32" alt="' + v.CallingName + '" />' } } } C += "</td></tr>" } C += "</table>"; y.html(C); y.find("a").each(function() { g(this).click(function(I) { window.open(this.href); I.preventDefault() }) }) }; var s = g.shareiton = function() { var v = this; return v }; s.init = function() { o = e("sio:button", window.sioBid); r = e("sio:language", "en"); c = e("og:image", null); j = e("og:video", null); k = e("og:siteName", null); u = e("og:type", "article"); d = e("og:url", sioGetCanonicalUrl()); n = e("og:title", document.title); a = g(".sioFbLike").length; var w = navigator.userAgent.toLowerCase(); h = ((w.indexOf("iphone") != -1) || (w.indexOf("blackberry") != -1) || (w.indexOf("android") != -1) || (w.indexOf("opera mini") != -1) || (w.indexOf("palm") != -1)); g("head").append('<link rel="stylesheet" type="text/css" href="' + sioUrl + '/Content/BtnAndVisit-1.2.css" />'); var v = []; g(".sioSharePanel").each(function() { g(this).sioSetUpButtonLink(); g(this).sioSetUpButtonLook(v) }); if (a || v.length > 0) { g.getJSON(sioUrl + "/Widget/GetInfoForButton?callback=?", { links: v, lang: r }, function(x) { if (x.status == "OK") { if (x.linksCount > 0) { g(".sioSharePanel").each(function() { g(this).sioUpdateButtonCounts(x) }) } if (a) { sioLoadFb(x.fbApp, x.local) } } }) } sioLoadColorBox(sioSetUpVisitPanel); sioLoadPopularContent() }; g(s.init) });
