JavaScript- Let's Reverse-Engineer Some Anti-AdBlock From asset.pagefair.net/ads.min.js

Posted at




(function z(c, e, p) {
function k(a, m) {
if (!e[a]) {
if (!c[a]) {
var d = "function" == typeof require && require;
if (!m && d) return d(a, !0);
if (l) return l(a, !0);
d = Error("Cannot find module '" + a + "'");
throw d.code = "MODULE_NOT_FOUND", d;
}
d = e[a] = {
a: {}
};
c[a][0].call(d.a, function (d) {
var e = c[a][1][d];
return k(e ? e : d)
}, d, d.a, z, c, e, p)
}
return e[a].a
}
for (var l = "function" == typeof require && require, g = 0; g < p.length; g++) k(p[g]);
return k
})({
1: [function (b) {
var c = b("./lib/ads")
, e = b("./lib/utils")
, p = b("./lib/config-advertising")
, k = b("./lib/detection")(p)
, l = b("./lib/cookies")(p);
k.V(!1, function (b, a, m, d) {
b = b && !d;
a = !(l.M() || l.N());
m = !0 !== c.r.aa;
d = e.A("pagefair_ad_demo");
(b && a && m || d) && c.U()
})
}, {
"./lib/ads": 16
, "./lib/config-advertising": 21
, "./lib/cookies": 22
, "./lib/detection": 23
, "./lib/utils": 25
}]
, 2: [function (b, c) {
c.a = '
'
}, {}]
, 3: [function (b, c) {
c.a = '

'
}, {}]
, 4: [function (b, c) {
c.a = '
'
}, {}]
, 5: [function (b, c) {
c.a = '

'
}, {}]
, 6: [function (b, c) {
c.a = '
'
}, {}]
, 7: [function (b, c) {
c.a = '
'
}, {}]
, 8: [function (b, c) {
c.a = '

'
}, {}]
, 9: [function (b, c) {
c.a = '
Advertisement
'
}, {}]
, 10: [function (b, c) {
c.a = '
Advertisement
'
}, {}]
, 11: [function (b, c) {
c.a = '
'
}, {}]
, 12: [function (b, c) {
c.a = '
'
}, {}]
, 13: [function (b, c) {
c.a = ''
}, {}]
, 14: [function (b, c) {
c.a = ''
}, {}]
, 15: [function (b, c) {
c.a = ''
}, {}]
, 16: [function (b, c) {
function e(a, f, A, b) {
var e = /.{1,2}\\/images\\/([^)']+)/;
a = jQuery(b)
.attr("id", f)
.wrap("
")
.parent()
.find("*")
.each(function () {
var a = jQuery(this)
.attr("class");
jQuery(this)
.attr("class", d(a, A));
(a = jQuery(this)
.attr("style")) && jQuery(this)
.attr("style", a.replace(e, n + "$1"))
})
.end();
return jQuery(a)
.html()
}

function p(a) {
var v = f.B.parse(a);
if ("OK" === v.status) {
if ("OK" == v.get_ops.status) {
var d = v.get_ops.ops;
for (a = 0; a < d.length; a++) {
var b = d[a];
if ("BACKOFF" == b.op_code) {
var e = new Date;
e.setSeconds(e.getSeconds() + b.sa);
r.g("bm_backoff", !0, e)
}
}
}
if ("OK" === v.get_ads.status)
for (v = v.get_ads.ads, a = 0; a < v.length; a++) d = v[a], b = w[d.ad_type], void 0 === b && (b = w.SEARCH_AD), u(d, b)
}
}

function k(a, f, d, b) {
a = b.ad_space_id;
jQuery(d)
.insertAfter("div[id=" + a + "]");
return jQuery("#" + f)
}

function l() {
var a = t()
, d = q();
if (a || d) {
var b = {};
b.website_code = h.m;
a && (b.first_daily = !0);
d && (b.first_monthly = !0);
f.h(h.k + "/stats/unique_shown_ad/a.js", b, null, !0)
}
}

function g(b) {
if (f.browser.mozilla) {
var d = []
, e = null;
b.parents(":hidden")
.each(function (f
, b) {
var y = jQuery(b)
.get(0)
, c = m(y);
c.MozBinding = "none";
c.display = a(y);
c.visibility = "visible";
d.push({
type: y.tagName.toLowerCase()
, style: c
});
e = b
});
if (null != e) {
d.reverse();
var c = jQuery("<" + d[0].type + "/>")
.insertAfter(e);
c.css(d[0].style);
for (i = 1; i < d.length; i++) c = jQuery("<" + d[i].type + "/>")
.appendTo(c), c.css(d[i].style);
b = b.detach();
c.append(b)
}
} else b.parents(":hidden")
.each(function (f, b) {
var d = jQuery(b)
.get(0)
, d = a(d)
, y = jQuery(b)
.attr("style");
jQuery(b)
.attr("style", y + ";display: " + d + " !important; visibility: visible !important;")
})
}

function a(a) {
a = {
span: "inline-block"
, div: "block"
, p: "block"
, ol: "block"
, ul: "block"
, li: "list-item"
, table: "table"
, tr: "table-row"
, th: "table-cell"
, td: "table-cell"
}[a.tagName.toLowerCase()];
"undefined" == typeof a && (a = "inline");
return a
}

function m(a) {
var f, b = {};
if (window.getComputedStyle) {
var d = function (a, f) {
return f.toUpperCase()
};
f = window.getComputedStyle(a, null);
for (a = 0; a < f.length; a++) {
var e = f[a]
, c = e.replace(/\\-([a-z])/g, d)
, e = f.getPropertyValue(e);
b[c] = e
}
return b
}
if (f = a.currentStyle) {
for (e in f) b[e] = f[e];
return b
}
return a.css()
}

function d(a, f) {
for (var b = a.split(" "), d = 0; d < b.length; d++) b[d] = f[b[d]];
return b.join(" ")
}

function t() {
return !0 !== s.daily_shown_ad ? (r.g("bm_daily_shown_ad", !0, f.c.v), s.daily_shown_ad = !0) : !1
}

function q() {
return !0 !== s.monthly_shown_ad ? (r.g("bm_monthly_shown_ad", !0, f.c.u), s.monthly_shown_ad = !0) : !1
}

function u(a, b) {
var d = b.n;
if ("OK" === a.status) {
l();
var c = b.f(a)
, n = jQuery(x.f(a.iab_unit))
.children()
, c = jQuery(c)
.append(n)
, n = f.b()
, c = e(0, n, d, c)
, c = k(0, n, c, a);
b.d(c, a);
x.d(c, d);
d = a.tracking_urls;
for (n = 0; n < d.length; n++) {
var m = document.createElement("IMG");
m.style.width = "1px";
m.style.height = "1px";
m.style.top = "-1000px";
m.style.left = "-1000px";
document.body.appendChild(m);
m.src = d[n]
}
g(c)
}
}
var h = b("../config-advertising")
, r = b("../cookies")(h)
, f = b("../utils")
, x = b("./menu.js")
, n = h.G + "/static/" + h.q + "images/"
, w = {
SEARCH_AD: b("./search_ads.js")
, DEMO_AD: b("./search_ads.js")
, AFFILIATE_AD: b("./affiliate_ads.js")
}
, s = {
monthly_shown_ad: r.e("bm_monthly_shown_ad", "BOOL")
, daily_shown_ad: r.e("bm_daily_shown_ad"
, "BOOL")
, backoff: r.e("bm_backoff")
};
c.a = {
r: s
, U: function () {
var a = [];
jQuery(".pagefair-acceptable")
.each(function (f, b) {
var d = jQuery(b)
.attr("id");
a.push(d)
});
if (0 !== a.length) {
var b = {
website_code: h.m
, ad_spaces: f.B.stringify(a)
, current_url: f.j()
, previous_url: f.T()
};
f.A("pagefair_ad_demo") && (b.ad_demo = !0);
f.h(h.I + "/ad_call", b, p)
}
}
, qa: l
, na: t
, oa: q
, ma: k
, ca: e
, pa: u
}
}, {
"../config-advertising": 21
, "../cookies": 22
, "../utils": 25
, "./affiliate_ads.js": 17
, "./menu.js": 18
, "./search_ads.js": 19
}]
, 17: [function (b, c) {
function e(a) {
var b =
jQuery(k)
, d = b.find("#nohover")
, c = b.find("#hover");
a.find("." + g.product)
.each(function () {
var a = this;
jQuery(this)
.hover(function () {
jQuery(a)
.css("background-color", c.css("background-color"));
jQuery(a)
.css("background", c.css("background"));
jQuery(a)
.css("filter", c.css("filter"))
}, function () {
jQuery(a)
.css("background-color", d.css("background-color"));
jQuery(a)
.css("background", d.css("background"));
jQuery(a)
.css("filter", d.css("filter"))
})
})
}
var p = b("../utils")
, k = b("./ad_templates/affiliate/html/product_hover.html")
, l = {
leaderboard_728_90: b("./ad_templates/affiliate/html/leaderboard_728_90.html")
, P: b("./ad_templates/affiliate/html/leaderboard_728_90_product.html")
, medium_rectangle_300_250: b("./ad_templates/affiliate/html/medium_rectangle_300_250.html")
, Q: b("./ad_templates/affiliate/html/medium_rectangle_300_250_product.html")
, wide_skyscraper_160_600: b("./ad_templates/affiliate/html/wide_skyscraper_160_600.html")
, $: b("./ad_templates/affiliate/html/wide_skyscraper_160_600_product.html")
}
, g = function () {
var a = p.b;
return {
productRecommendations: a()
, product: a()
, productName: a()
, display_url: a()
, description: a()
, title: a()
, callToAction: a()
, productImage: a()
, ad_menu: a()
, menu_item: a()
, vote_up: a()
, vote_down: a()
, more_info: a()
, opt_out: a()
, feedback_overlay: a()
, feedback_message: a()
}
}();
c.a = {
f: function (a) {
var b = a.iab_unit
, d;
a = a.content;
var c = 0
, e = jQuery(l[b]);
"leaderboard_728_90" === b ? (d = l.P, c = 3) : "medium_rectangle_300_250" === b ? (d = l.Q, c = 2) : "wide_skyscraper_160_600" === b && (d = l.$, c = 2);
for (var b = ["Buy Now", "For Sale", "Get This"]
, k = 0; k < c; k++) {
var h = a[k]
, g = jQuery(d);
g.attr("href", h.click_url);
g.find(".title")
.html(h.title);
var f = b[k % b.length];
g.find(".callToAction")
.html(f);
g.find(".productImage")
.attr("src", h.image_url);
e.append(g)
}
return e.wrap("
")
.parent()
.html()
}
, n: g
, d: function (a) {
e(a)
}
}
}, {
"../utils": 25
, "./ad_templates/affiliate/html/leaderboard_728_90.html": 2
, "./ad_templates/affiliate/html/leaderboard_728_90_product.html": 3
, "./ad_templates/affiliate/html/medium_rectangle_300_250.html": 4
, "./ad_templates/affiliate/html/medium_rectangle_300_250_product.html": 5
, "./ad_templates/affiliate/html/product_hover.html": 6
, "./ad_templates/affiliate/html/wide_skyscraper_160_600.html": 7
, "./ad_templates/affiliate/html/wide_skyscraper_160_600_product.html": 8
}]
, 18: [function (b, c) {
function e(b, d) {
b.hover(function () {
b.find("." + d.ad_menu)
.fadeIn(200)
}, function () {
b.find("." + d.ad_menu)
.fadeOut(200)
});
b.find("." + d.menu_item)
.hover(function () {
var b = jQuery(a)
.find(".menu_item.force_hover");
jQuery(this)
.css("background-color", b.css("background-color"))
}, function () {
var b = jQuery(a)
.find(".menu_item");
jQuery(this)
.css("background-color", b.css("background-color"))
})
}

function p(a, b) {
a.find("." + b.vote_up + ", ." + b.vote_down)
.click(function (c) {
c.preventDefault();
c.stopPropagation();
c = jQuery(this)
.parents("." + b.click_url)
.attr("href");
c = d.l(c);
var e;
jQuery(this)
.hasClass("." + b.vote_up) ? e = m.k + "/stats/vote_up/" : jQuery(this)
.hasClass("." + b.vote_down) && (e = m.k + "/stats/vote_down/");
d.h(e, {
website_code: m.m
, display_url: c
});
a.find("." + b.feedback_message)
.html("Thank you! Your feedback helps improve advertising on this site");
a.find("." + b.feedback_overlay)
.fadeIn(200)
});
k(a.find("." + b.more_info), m.H + "/ad_server/more_info/?referer_url=" + d.l(d.j()));
k(a.find("." + b.opt_out), m.H + "/ad_server/opt_out/?referer_url=" + d.l(d.j()))
}

function k(a, b) {
a.click(function (a) {
a.preventDefault();
a.stopPropagation();
t.W(b, !0)
})
}
var l = b("./ad_templates/common/html/menu_bar_horizontal.html")
, g = b("./ad_templates/common/html/menu_bar_vertical.html")
, a = b("./ad_templates/common/html/menu_items.html")
, m = b("../config-advertising")
, d = b("../utils")
, t = b("../modals")(m);
c.a = {
f: function (a) {
if ("leaderboard_728_90" === a || "medium_rectangle_300_250" === a) return g;
if ("wide_skyscraper_160_600" === a) return l
}
, d: function (a, b) {
p(a, b);
e(a, b)
}
}
}, {
"../config-advertising": 21
, "../modals": 24
, "../utils": 25
, "./ad_templates/common/html/menu_bar_horizontal.html": 9
, "./ad_templates/common/html/menu_bar_vertical.html": 10
, "./ad_templates/common/html/menu_items.html": 11
}]
, 19: [function (b, c) {
function e(a) {
a.find("." + g.ad_icon)
.css("background-color", "");
a.hover(function () {
var b =
jQuery(k)
.find(".ad_icon.force_hover");
a.find("." + g.ad_icon)
.css("background-color", b.css("background-color"));
a.find("." + g.ad_icon)
.css("color", b.css("color"))
}, function () {
a.find("." + g.ad_icon)
.css("background-color", "");
a.find("." + g.ad_icon)
.css("color", "#cd0648")
})
}
var p = b("../utils")
, k = b("./ad_templates/search/html/ad_icon.html")
, l = {
leaderboard_728_90: b("./ad_templates/search/html/leaderboard_728_90.html")
, medium_rectangle_300_250: b("./ad_templates/search/html/medium_rectangle_300_250.html")
, wide_skyscraper_160_600: b("./ad_templates/search/html/wide_skyscraper_160_600.html")
}
, g = function () {
var a = p.b;
return {
pfcontainer: a()
, click_url: a()
, title: a()
, display_url: a()
, description: a()
, ad_icon: a()
, label: a()
, ad_menu: a()
, menu_item: a()
, vote_up: a()
, vote_down: a()
, more_info: a()
, opt_out: a()
, feedback_overlay: a()
, feedback_message: a()
, "vertical-align-outer": a()
, "vertical-align-inner": a()
}
}();
c.a = {
f: function (a) {
var b = jQuery(l[a.iab_unit])
, d = a.title
, c = a.description;
b.find(".title")
.html(d);
b.find(".description")
.html(c);
d = a.display_url;
a = a.click_url; - 1 < d.indexOf("http") && (d = d.replace(/^http:\\/\\//, ""));
d = d.replace(/(\\/$)/g, "");
b.find(".display_url")
.html(d);
b.find(".click_url")
.attr("href", a);
return b.wrap("
")
.parent()
.html()
}
, n: g
, d: function (a) {
e(a)
}
}
}, {
"../utils": 25
, "./ad_templates/search/html/ad_icon.html": 12
, "./ad_templates/search/html/leaderboard_728_90.html": 13
, "./ad_templates/search/html/medium_rectangle_300_250.html": 14
, "./ad_templates/search/html/wide_skyscraper_160_600.html": 15
}]
, 20: [function (b, c) {
c.a = {
J: "v1d8e07/"
}
}, {}]
, 21: [function (b, c) {
var e = b("../utils")
, p = b("../cache_buster");
c.a = {
o: e.protocol + "asset.pagefair.com"
, Z: e.protocol + "asset.pagefair.net"
, q: "undefined" !== typeof bm_cache_buster ? bm_cache_buster : p.J
, i: "ads_"
, ba: "ads_"
, m: bm_website_code
, G: e.protocol + ("undefined" !== typeof bm_static_location ? bm_static_location : "pagefair.net")
, H: e.protocol + ("undefined" !== typeof bm_website_location ? bm_website_location : "pagefair.net")
, k: e.protocol + ("undefined" !== typeof bm_stats_location ? bm_stats_location :
"stats.pagefair.net")
, I: e.protocol + ("undefined" !== typeof bm_ads_location ? bm_ads_location : "adfeed.pagefair.net")
}
}, {
"../cache_buster": 20
, "../utils": 25
}]
, 22: [function (b, c) {
var e = b("../utils");
c.a = function (b) {
function c(a, m) {
a = b.i + a;
for (var d = a + "=", k = document.cookie.split(/[;&]/), g = "null", l = 0; l < k.length; l++) {
for (var h = k[l];
" " === h.charAt(0);) h = h.substring(1, h.length);
0 === h.indexOf(d) && (g = h.substring(d.length, h.length))
}
d = g;
"null" == g ? d = null : ("string" == e.type(g) && (d = g.replace(/___/g, ";")), void 0 !== m &&
("ARRAY" == m ? d = d.split(",") : "INT" == m ? d = parseInt(d) : "BOOL" == m && (d = "true" == d)));
return d
}

function l(a) {
a = b.i + a;
document.cookie = a + "=; expires=Mon, 20 Sep 2010 00:00:00 UTC; path=/"
}

function g(a, c, d) {
a = b.i + a;
void 0 === d && (d = e.c.K);
var g = c;
null === c ? g = "null" : (e.isArray(c) && (g = c.join(",")), "string" === e.type(g) && (g = g.replace(/;/g, "___")));
l(a);
document.cookie = a + "=" + g + "; expires=" + d.toUTCString() + "; path=/"
}
return {
e: c
, g: g
, ha: l
, M: function () {
var a = e.w("bm_dts");
null != a && (a = e.Y(a), a > e.c.now && g("bm_donor", 1, a));
return null != c("bm_donor")
}
, N: function () {
null != e.w("bm_opted_out") && g("bm_opted_out", 1, e.c.F);
return null != c("bm_opted_out")
}
}
}
}, {
"../utils": 25
}]
, 23: [function (b, c) {
var e = b("../utils");
c.a = function (c) {
function k(a) {
var b = []
, f = document.createElement("DIV");
f.className = "AdHere";
f.style.width = "1px";
f.style.height = "1px";
f.style.top = "-1000px";
f.style.left = "-1000px";
document.body.appendChild(f);
setTimeout(function () {
var c = window.getComputedStyle(f)
.getPropertyValue("-moz-binding");
c && -1 !== c.indexOf("abp-elemhidehit") &&
b.push("adblock_plus");
f.remove && f.remove();
a({
firefox: b
})
}, 1E3)
}

function l(a) {
if (e.O("1.5.1")) {
var b = {
adblock: "chrome-extension://gighmmpiobklfepjocnamgkkbiglidom/img/icon24.png"
, adblock_plus: "chrome-extension://cfhdojbkjhnklbpkdaibdccddilifddb/block.html"
, adblock_pro: "chrome-extension://ocifcklkibdehekfnmflempfgjhbedch/components/block/block.html"
, adblock_premium: "chrome-extension://fndlhnanhedoklpdaacidomdnplcjcpj/img/icon24.png"
, adblock_super: "chrome-extension://knebimhcckndhiglamoabbnifdkijidd/widgets/block/block.html"
, adguard: "chrome-extension://bgnkhhnnamicmpeenaelnjfhikgbkllg/elemhidehit.png"
, adremover: "chrome-extension://mcefmojpghnaceadnghednjhbmphipkb/img/icon24.png"
, ublock: "chrome-extension://epcnnfbjfcgphgdmggkamkmgojdagdnn/document-blocked.html"
}
, f = []
, c = 0
, d = function (d, n) {
jQuery.ajax({
url: n
, success: function () {
f.push(d)
}
, complete: function () {
c += 1;
c === e.t(b) && a({
chrome: f
})
}
})
}
, n;
for (n in b) d(n, b[n])
} else a()
}

function g() {
if (e.t(h) === n.length && !w) {
w = !0;
for (var b = 0; b < n.length; b++)
if (void 0 == h[n[b]]) throw "Invalid test in results: " +
n[b];
var b = a()
, f;
a: {
for (f = 0; f < x.length; f++) {
var c = h[x[f]];
if (void 0 === c || 1 === c) {
f = !1;
break a
}
}
f = !0
}
c = b && "NOT_BLOCKING" == u.C || !b && "BLOCKING" == u.C;
q.g("bm_last_load_status", b ? "BLOCKING" : "NOT_BLOCKING");
void 0 !== s && jQuery.isFunction(s) && s(b, f, h, c)
}
}

function a() {
for (var a = 0; a < r.length; a++) {
var b = r[a];
if (1 === h[b]) {
for (a = 0; a < f.length; a++)
if (b = f[a], 1 === h[b]) return !1;
return !0
}
}
return !1
}

function m(a, b, f) {
var c = document.createElement("DIV");
c.id = f;
c.className = b;
c.style.width = "1px";
c.style.height = "1px";
c.style.top =
"-1000px";
c.style.left = "-1000px";
document.body.appendChild(c);
b = jQuery("#" + f);
f = b.is(":hidden") ? 1 : 0;
h[a + "_hid_t0"] = e.browser.mozilla ? 0 : f;
b.remove();
g()
}

function d(a) {
function b(a) {
var c = e.s(h);
0 < e.D(c, "s_blk") || (c = jQuery("#" + f), h.s_blk = a, c.remove(), g())
}
var f = e.b()
, c = document.createElement("SCRIPT");
9 > e.L || e.browser.safari || e.browser.mozilla ? setTimeout(function () {
b(0)
}, 1) : (jQuery(c)
.load(function () {
b(0)
}), jQuery(c)
.error(function () {
b(1)
}));
c.id = f;
c.type = "text/javascript";
document.getElementsByTagName("head")[0].appendChild(c);
c.src = a
}

function t(a, b) {
function f(b) {
var d = e.s(h);
0 < e.D(d, a + "_blk") || (d = jQuery("#" + c), h[a + "_blk"] = b, d.remove(), g())
}
var c = e.b()
, d = document.createElement("IMG");
e.browser.safari || e.browser.msie ? setTimeout(function () {
f(0)
}, 1) : (jQuery(d)
.load(function () {
f(0)
}), jQuery(d)
.error(function () {
f(1)
}));
d.id = c;
d.style.width = "1px";
d.style.height = "1px";
d.style.top = "-1000px";
d.style.left = "-1000px";
document.body.appendChild(d);
d.src = b
}
var q = b("../cookies")(c)
, u = {
C: q.e("bm_last_load_status")
}
, h = {}
, r = ["i_blk", "s_blk"
, "div_hid_t0"
]
, f = []
, x = ["wl_i_blk", "wl_div_hid_t0"]
, n = []
, w = !1
, s;
return {
V: function (a, b) {
w && (w = !1, h = {});
s = b;
n = r.concat(f);
!0 == a && (n = n.concat(x), t("wl_i", c.Z + "/adimages/textlink-ads.jpg"), m("wl_div", "", "influads_block"));
t("i", c.o + "/adimages/textlink-ads.jpg");
d(c.o + "/adimages/adsense.js");
m("div", "AdHere", e.b())
}
, r: u
, ga: r
, va: x
, ja: function (a) {
e.browser.chrome ? l(a) : e.browser.mozilla ? k(a) : a()
}
, ia: l
, ka: k
}
}
}, {
"../cookies": 22
, "../utils": 25
}]
, 24: [function (b, c) {
c.a = function (b) {
function c(l, g) {
var a;
void 0 !==
k ? (!0 === g && jQuery(k)
.find("#modal-content")
.html(l), jQuery(k)
.show(), a = !1) : (jQuery("head")
.prepend(''), a = '", k = jQuery(a)
.appendTo("body")
, jQuery(k)
.find("#modal-content")
.html(l), jQuery(k)
.find("#modal-close")
.click(function () {
jQuery(k)
.hide()
}), jQuery(k)
.find("#modal-size")
.click(function (a) {
var b = $("#modal-dialog-box");
b.is(a.target) || 0 !== b.has(a.target)
.length || jQuery(k)
.hide()
}), a = !0);
return a
}
var k;
return {
W: function (b, e) {
return c('', e)
}
, ta: c
}
}
}, {}]
, 25: [function (b, c) {
function e(a) {
var b = "?";
for (key in a) b += encodeURIComponent(key) + "=" + encodeURIComponent(a[key]) +
"&";
return b.substring(0, b.length - 1)
}

function p(a) {
a = a.split(".");
for (var b = jQuery.fn.jquery.split("."), c = 0; c < b.length; c++) {
b[c] = parseInt(b[c], 10);
a[c] = parseInt(a[c], 10);
if (b[c] > a[c]) break;
if (a[c] > b[c]) return !1
}
return !0
}

function k() {
return Math.random()
}

function l(a) {
return a in h
}

function g(a) {
var b = []
, c;
for (c in a) a.hasOwnProperty(c) && b.push(c);
return b
}

function a(a) {
return null == a ? String(a) : u[Object.prototype.toString.call(a)] || "object"
}

function m(a) {
a = a.toLowerCase();
a = /(maxthon)[ \\/]([\\w.]+)/.exec(a) ||
/(ucbrowser)[ \\/]([\\w.]+)/.exec(a) || /(chrome)[ \\/]([\\w.]+)/.exec(a) || /(webkit)[ \\/]([\\w.]+)/.exec(a) || /(opera)(?:.*version|)[ \\/]([\\w.]+)/.exec(a) || /(msie) ([\\w.]+)/.exec(a) || 0 > a.indexOf("compatible") && /(mozilla)(?:.*? rv:([\\w.]+)|)/.exec(a) || [];
matched = {
browser: a[1] || ""
, version: a[2] || "0"
};
q = {};
matched.browser && (q[matched.browser] = !0, q.version = matched.version);
q.da ? q.webkit = !0 : q.webkit && (q.safari = !0);
return q
}
var d = "https:" == document.location.protocol ? "https://" : "http://"
, t = function () {
var a = 3
, b = document.createElement("div")
, c;
do b.innerHTML = "", c = 0 < b.getElementsByTagName("i")
.length ? !0 : !1; while (c);
return 4 < a ? a : void 0
}()
, q = m(window.navigator.userAgent)
, u = function () {
var a = {};
jQuery.each("Boolean Number String Function Array Date RegExp Object".split(" "), function (b, c) {
a["[object " + c + "]"] = c.toLowerCase()
});
return a
}()
, h = function () {
request_params = {};
for (var a, b = window.location.href.slice(window.location.href.indexOf("?") + 1)
.split("&"), c = 0; c < b.length; c++) a = b[c].split("="), request_params[a[0]] =
a[1];
return request_params
}()
, r = function () {
var a = {};
a.now = new Date;
a.v = new Date(a.now.getTime());
a.v.setHours(23, 59, 59, 999);
a.u = new Date(a.now.getFullYear(), a.now.getMonth() + 1, 0);
a.u.setHours(23, 59, 59, 999);
a.X = new Date(a.now.getTime());
a.X.setDate(a.now.getDate() + 1);
a.S = new Date(a.now.getTime());
a.S.setDate(a.now.getDate() + 7);
a.R = new Date(a.now.getTime());
a.R.setDate(a.now.getDate() + 14);
a.F = new Date(a.now.getTime());
a.F.setDate(a.now.getDate() + 28);
a.K = new Date(2030, 11, 31);
return a
}();
c.a = {
protocol: d
, L: t
, ua: m
, browser: q
, ea: u
, type: a
, isArray: function (b) {
return "array" === a(b)
}
, now: function () {
return (new Date)
.getTime()
}
, B: {
parse: function (a) {
return void 0 !== JSON ? JSON.parse(a) : jQuery.parseJSON(a)
}
, stringify: function (a) {
var b;
window.Prototype && (b = Array.prototype.toJSON, delete Array.prototype.toJSON);
a = JSON.stringify(a);
window.Prototype && (Array.prototype.toJSON = b);
return a
}
}
, D: function (a, b) {
return jQuery.grep(a, function (a) {
return a == b
})
.length
}
, s: g
, la: function (a) {
var b = []
, c;
for (c in a) a.hasOwnProperty(c) &&
b.push(a[c]);
return b
}
, t: function (a) {
return g(a)
.length
}
, ra: h
, A: l
, w: function (a) {
return l(a) ? h[a] : null
}
, c: r
, Y: function (a) {
return new Date(1E3 * a)
}
, l: function (a) {
return encodeURIComponent(a)
}
, b: function () {
var a = (new Date)
.getTime();
return "xxxxxxxx".replace(/[xy]/g, function (b) {
var c = (a + 16 * k()) % 16 | 0;
a = Math.floor(a / 16);
return ("x" == b ? c : c & 7 | 8)
.toString(16)
})
}
, random: k
, O: p
, fa: e
, h: function (a, b, c, d) {
b = b || {};
d = d || !1;
c = c || null;
var g = !0;
if ("undefined" !== typeof XMLHttpRequest && "withCredentials" in new XMLHttpRequest &&
p("1.5.2")) {
var g = !1
, h = {};
h.url = a;
h.type = "GET";
h.data = b;
h.cache = !1;
h.dataType = "text";
d && (h.xhrFields = {
withCredentials: !0
});
null != c && (h.success = c);
jQuery.ajax(h)
}
g && (null != c && (d = ("r" + k())
.replace(".", ""), b.cbfnc = d, window[d] = c), b._ = k(), c = document.createElement("SCRIPT"), c.src = a + e(b), c.type = "text/javascript", (document.head || document.getElementsByTagName("head")[0])
.appendChild(c))
}
, j: function () {
return window.location.href != window.parent.location.href ? document.referrer : document.location.href
}
, T: function () {
return document.referrer
}
}
}, {}]
}, {}, [1]);