Skip to content

Instantly share code, notes, and snippets.

@theseanl
Created January 23, 2017 13:23
Show Gist options
  • Save theseanl/b81e1d7689d07c086338d6a1bd482acb to your computer and use it in GitHub Desktop.
Save theseanl/b81e1d7689d07c086338d6a1bd482acb to your computer and use it in GitHub Desktop.
try {
var pv = 2
, rpn = Math.floor(1e3 * Math.random()) + 1;
if (rpn < pv) {
!function(e, t, n, r, i, a, o) {
e.GoogleAnalyticsObject = i,
e[i] = e[i] || function() {
(e[i].q = e[i].q || []).push(arguments)
}
,
e[i].l = 1 * new Date,
a = t.createElement(n),
o = t.getElementsByTagName(n)[0],
a.async = 1,
a.src = r,
o.parentNode.insertBefore(a, o)
}(window, document, "script", "https://www.google-analytics.com/analytics.js", "ga"),
ga("create", "UA-63935000-17", {
name: "r1zt"
}),
ga("r1zt.set", "dimension1", "allmusic"),
ga("r1zt.set", "dimension2", "header"),
ga("r1zt.set", "dimension3", window === window.top ? "yes" : "no");
var isPop = "unknown";
try {
isPop = window === window.top ? window.opener ? "yes" : "no" : window.top.opener ? "yes" : "no"
} catch (err) {
isPop = "unknown"
}
ga("r1zt.set", "dimension4", isPop),
ga("r1zt.send", "pageview")
}
} catch (err) {}
!function e(t, n, r) {
function i(o, c) {
if (!n[o]) {
if (!t[o]) {
var s = "function" == typeof require && require;
if (!c && s)
return s(o, !0);
if (a)
return a(o, !0);
var l = new Error("Cannot find module '" + o + "'");
throw l.code = "MODULE_NOT_FOUND",
l
}
var d = n[o] = {
exports: {}
};
t[o][0].call(d.exports, function(e) {
var n = t[o][1][e];
return i(n ? n : e)
}, d, d.exports, e, t, n, r)
}
return n[o].exports
}
for (var a = "function" == typeof require && require, o = 0; o < r.length; o++)
i(r[o]);
return i
}({
1: [function(e, t, n) {
function r() {
"undefined" != typeof document && ("undefined" != typeof document.hidden ? (a = "hidden",
o = "visibilitychange") : "undefined" != typeof document.mozHidden ? (a = "mozHidden",
o = "mozvisibilitychange") : "undefined" != typeof document.msHidden ? (a = "msHidden",
o = "msvisibilitychange") : "undefined" != typeof document.webkitHidden && (a = "webkitHidden",
o = "webkitvisibilitychange"),
o && a && (document.addEventListener && document.addEventListener(o, function() {
f.isViewable = s = document[a] === !0 ? 0 : 1
}, !1),
f.isViewable = s = document[a] === !0 ? 0 : 1))
}
function i() {
try {
r()
} catch (err) {}
if (f.global.zScriptCount < 0 && (f.global.zScriptCount = 0),
l && 0 !== f.global.zScriptCount)
setTimeout(i, 50);
else {
var t = e("./reports.js")(f);
window.addEventListener && window.addEventListener("beforeunload", function() {
t.report({
event: "ztag-unload",
viewability: f.isViewable
})
}, !1),
e("./waterfalls.js")(f),
new (e("./dwrite.js"))(f),
t.report({
event: "ztag-start",
viewability: f.isViewable
});
var n = e("../constructors/Placer.js")({
zData: f,
reporter: t,
utilities: d,
writer: function(e) {
"script" === e.type ? document.write('<script type="text/javascript">' + e.value + "</script>") : "html" === e.type && document.write(e.value)
}
});
try {
n.place({
"name": "header",
"items": [],
"tags": {},
"conditions": {},
"rules": {}
})
} catch (err) {
t.report({
event: "ztag-error",
details: err.toString(),
viewability: f.isViewable
})
}
t.report({
event: "ztag-end",
viewability: f.isViewable
})
}
}
var a, o, c = window || this, s = 2, l = /MSIE ([5-9]|10)/.test(navigator.userAgent);
c.console || (c.console = {
log: function(e) {}
});
var d = e("../constructors/Utilities.js")()
, u = {
edge: /edge/i,
ie: /(msie|trident)/i,
chrome: /(chrome|crios)/i,
firefox: /(firefox|fxios)/i,
safari: /safari/i,
opera: /(opera|opios)/i
}
, p = "unknown";
for (var g in u)
if (u[g].test(navigator.userAgent)) {
p = g;
break
}
var f = {
ztagId: d.uuid(),
global: c,
version: "1.1.35",
publisherId: "allmusic",
placementId: "header",
salt: Math.round(1e9 * Math.random()).toString(36),
device: /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ? "mobile" : "desktop",
iframe: window === window.top ? "no" : "yes",
browser: p,
isViewable: s
};
try {
f.isPop = window === window.top ? window.opener ? 1 : 0 : window.top.opener ? 1 : 0
} catch (err) {
f.isPop = 2
}
var m = document.currentScript || function() {
var e = document.getElementsByTagName("script")
, t = e[e.length - 1];
return d.forEach(e, function(e) {
e.src && d.queryString("pub", e.src) === f.publisherId && d.queryString("placement", e.src) === f.placementId && (t = e)
}),
t
}();
m || ((new Image).src = "//report-zt.1rx.io/ztagtrackedevent?version=" + f.version + "&publisherid=" + f.publisherId + "&placementid=" + f.placementId + "&domain=" + document.domain + "&include_header_list=Referer%2CAccept-Language%2CUser-Agent&doc_version=1&doc_type=ztag-event&event=ztag-error&details=invalidCurrentScript&cb=" + Math.random().toString(36).replace(/[^a-z]+/g, ""));
try {
if (f.currentScriptHost = "",
m && m.src) {
var h = m.src.match(/\/\/(.+?)\/.+/i);
h && h[1] && (f.currentScriptHost = h[1])
}
f.currentScriptHost || (f.currentScriptHost = "zt.1rx.io")
} catch (err) {
f.currentScriptHost = "zt.1rx.io"
}
f.target = c.__TARGET || m,
"number" != typeof f.global.zScriptCount && (f.global.zScriptCount = 0),
i()
}
, {
"../constructors/Placer.js": 5,
"../constructors/Utilities.js": 7,
"./dwrite.js": 2,
"./reports.js": 3,
"./waterfalls.js": 4
}],
2: [function(e, t, n) {
t.exports = function(e) {
function t(e) {
function t() {
var u = i;
if (h && (u = h),
n = u.exec(e)) {
if (u !== s || "'" !== n[1] && '"' !== n[1] && /\<\/script\b/i.test(n[0])) {
if (u === s) {
var f = n.index;
n = /(\<\/(script)\b)/i.exec(n[0]),
n.index += f
}
h = !1,
i.lastIndex = u.lastIndex,
n[0] = n[0].toLowerCase();
var m = l[n[0]];
if (m)
return g(m, n, d[n[0]], function(t) {
return e.substring(n.index, t.index + t[0].length)
});
var v = n[2].toLowerCase();
if (0 === n[0].indexOf("</"))
return g(/>/g, n, "closetag", function() {
return v
});
var w = {
type: "opentag",
index: n.index,
length: n[0].length,
value: v,
isVoid: a.test(v),
isRawText: o.test(v),
fragmented: !0
};
for (c.lastIndex = n.index + n[0].length; r = c.exec(e); )
if (w.length += r[0].length,
/\s*[\/]{0,1}\>$/.test(r[0])) {
w.fragmented = !1;
break
}
return i.lastIndex = w.index + w.length,
"opentag" === w.type && w.isRawText && (h = "script" === w.value ? s : new RegExp("(<\\/(" + w.value + ")\\b)","ig"),
h.lastIndex = w.index + w.length),
w
}
return t()
}
return p()
}
var n, r, i = /(<!doctype|<!--|<\/{0,1}([a-z][a-z0-9]*))/gim, a = /(area|base|br|col|command|embed|hr|img|input|keygen|link|meta|param|source|track|wbr)/i, o = /(script|style|textarea|title)/i, c = /(\s*[\/]{0,1}\>|\s+([a-z0-9-]+)(\s*[\/]{0,1}\>|(?=\s+[^=])|\s*=\s*(\>|[^'"][^\s\>]*|"[^"]*"|'[^']*')))/gim, s = /(?:(['"])(?:(?!\1)[^\\])*(?:\\(?:\\\\)*\1(?:(?!\1)[^\\])*|[\\]+(?:(?!\1).)*(?:(?!\1)[^\\])*)*\1|<\/script>)/gim, l = {
"<!doctype": />/g,
"<!--": /-->/g
}, d = {
"<!doctype": "doctype",
"<!--": "comment"
}, u = 0, p = function() {
return i.lastIndex = e.length,
{
type: "end"
}
}, g = function(t, n, a, o) {
return t.lastIndex = n.index + n[0].length,
r = t.exec(e),
r ? (i.lastIndex = r.index + r[0].length,
{
type: a,
value: o(r),
index: n.index,
length: r.index + r[0].length - n.index
}) : p()
}, f = null, m = !0, h = !1;
this.next = function() {
if (m) {
f = t(),
m = !1;
var n = {
type: "text",
index: u
};
if ("end" != f.type ? (n.value = e.substring(u, f.index),
n.length = n.value.length,
u = f.index + f.length) : (n.value = e.substring(u, e.length),
/<$/.test(n.value) && (n.value = n.value.substring(0, n.value.length - 1)),
n.length = n.value.length,
u = n.index + n.length),
n.rawValue = e.substr(n.index, n.length),
n.length > 0)
return n
}
return f.rawValue = e.substr(f.index, f.length),
m = !0,
f
}
}
function n(e, t) {
var n = /^<([a-z0-9]*)([\s\S]*?)>$/i.exec(e.substr(t.index, t.length));
if (n) {
for (var r = document.createElement(n[1]), i = function(e) {
return c.innerHTML = "<div " + e + "></div>",
c.childNodes[0].attributes
}(n[2]), a = 0; a < i.length; a++)
r.setAttribute(i[a].name, i[a].value);
return r
}
return !1
}
function r(e) {
try {
p.appendChild(e)
} catch (ex) {
e.failParent = p
}
}
function i() {
g = !1,
m > 0 && (window[d] = window[d].substring(m, window[d].length)),
f && (f = !1,
a(""))
}
function a(a) {
function o() {
var t = !1;
if ("object" == typeof (mark = h.next()) && "end" !== mark.type) {
if ("opentag" === mark.type) {
if (mark.fragmented)
return void i();
var a = n(c, mark);
if (a) {
if ("SCRIPT" == a.tagName && a.src && a.src.length > 0) {
if (t = !0,
e.global.zScriptCount++,
s) {
var d = document.currentScript;
document.currentScript = a
}
setTimeout(function() {
s && (document.currentScript = d),
e.global.zScriptCount--,
o()
}, 0)
}
r(a),
mark.isVoid || (p = a)
}
} else if ("closetag" === mark.type) {
for (var u = p; u.tagName.toLowerCase() !== mark.value && (u.parentElement || u.failParent); )
u = u.parentElement || u.failParent;
u.tagName.toLowerCase() === mark.value && (u.parentElement || u.failParent) && (p = u.parentElement || u.failParent)
} else if ("text" === mark.type)
if ("SCRIPT" === p.tagName)
l ? p.text = mark.value : (mark.value.trim && mark.value.trim().length > 0 || mark.value.replace(/\s/, "").length > 0) && (p.innerHTML = mark.value);
else
try {
p.appendChild(document.createTextNode(mark.value))
} catch (ex) {}
else if ("comment" === mark.type)
try {
p.appendChild(document.createComment(mark.value))
} catch (ex) {}
m = mark.index + mark.length,
t || o()
} else
i()
}
if (document.currentScript && document.currentScript !== u && (u = document.currentScript,
p = u.parentElement),
"string" != typeof window[d] && (window[d] = ""),
window[d] += a,
g === !0)
return void (f = !0);
m = 0,
g = !0;
var c = window[d]
, h = new t(c);
o()
}
function o(t) {
return "loading" == document.readyState && e.target.async !== !0 ? ("undefined" == typeof e.target.writeValidated && (window.writeValidated = !1,
document[e.salt]('<script type="text/javascript">window.writeValidated = true;</script>'),
e.target.writeValidated = window.writeValidated),
e.target.writeValidated === !0 ? document[e.salt](t) : a(t)) : a(t)
}
var c = (e.global,
document.createElement("div"))
, s = /(MSIE|Edge|Trident)/i.test(navigator.userAgent)
, l = /MSIE [5-8]/.test(navigator.userAgent)
, d = e.salt + "_buffer"
, u = e.target
, p = u.parentElement
, g = !1
, f = !1
, m = 0;
s && (document.currentScript = u),
document[e.salt] || (document[e.salt] = document.write),
document.write = o
}
}
, {}],
3: [function(e, t, n) {
t.exports = function(t) {
var n = (new Date).getTime()
, r = {
version: t.version,
ztagid: t.ztagId,
publisherid: t.publisherId,
placementid: t.placementId,
domain: document.domain,
st: n,
sst: function() {
return (new Date).getTime() - n
},
iframe: t.iframe || "unknown",
pop: "undefined" != typeof t.isPop ? t.isPop : 2,
device: t.device || "unknown",
browser: t.browser || "unknown",
include_header_list: "Referer,Accept-Language,User-Agent",
doc_version: 1,
doc_type: "ztag-event"
}
, i = "//report-" + t.currentScriptHost + "/ztagtrackedevent/img?";
return e("../constructors/Reporter.js")({
endPoint: i,
header: r,
mode: "client"
})
}
}
, {
"../constructors/Reporter.js": 6
}],
4: [function(e, t, n) {
t.exports = function(e) {
var t = e.global;
t.zTagContinue = function(e) {
if ("undefined" != typeof e && e || (e = "default"),
zTagState = t["zTagState_" + e],
zTagState instanceof Object && zTagState.tags instanceof Array && zTagState.index < zTagState.tags.length) {
var n = zTagState.tags[zTagState.index++];
zTagState.placer.inject(n)
}
}
}
}
, {}],
5: [function(require, module, exports) {
function Placer(e) {
return this instanceof Placer ? (this.zData = e.zData || {},
this.writer = e.writer || function() {}
,
this.reporter = e.reporter,
this.utilities = e.utilities,
this.localTagsPlaced = {},
this.placement = null,
this.macros = {
pageURL: "",
userAgent: "",
userAgentEncoded: "",
doNotTrack: "",
ipv4: "",
location: "",
appName: "",
bundleID: "",
IDFA: "",
appStoreURL: "",
cacheBuster: Math.floor(1e16 * Math.random())
},
void ("undefined" != typeof document && "undefined" != typeof navigator ? (this.macros.pageURL = encodeURIComponent(document.location.href),
this.macros.userAgent = navigator.userAgent,
this.macros.userAgentEncoded = encodeURIComponent(navigator.userAgent),
this.macros.doNotTrack = navigator.doNotTrack) : "undefined" != typeof e.request && (this.macros.pageURL = encodeURIComponent(e.request.get("referrer") || ""),
this.macros.userAgent = e.request.get("user-agent") || "",
this.macros.userAgentEncoded = encodeURIComponent(e.request.get("user-agent") || ""),
this.macros.ipv4 = e.request.get["x-forwarded-for"] || e.request.connection.remoteAddress))) : new Placer(e)
}
Placer.prototype.inject = function(e) {
if (e) {
var t = this.zData.global
, n = this;
if (this.reporter && "undefined" != typeof window ? this.reporter.report({
event: "ztag-tag-placed",
tagid: e.name,
viewability: this.zData.isViewable
}) : this.reporter && this.reporter.report({
event: "ztag-tag-placed",
tagid: e.name,
version: this.zData.version,
publisherid: this.zData.publisherId,
placementid: this.zData.placementId,
include_header_list: "Referer,Accept-Language,User-Agent",
viewability: this.zData.isViewable
}),
e.active)
try {
e.value = e.value.replace(/<=tagid>/gi, e.name),
e.value = e.value.replace(/<=ztagid>/gi, n.zData.ztagId),
e.value = e.value.replace(/<=pub>/gi, n.zData.publisherId),
e.value = e.value.replace(/<=placement>/gi, n.zData.placementId),
e.value = e.value.replace(/<=([a-z0-9_-]+)>/gi, function(e, t) {
return "undefined" != typeof n.macros[t] ? n.macros[t] : e
}),
e.value = e.value.replace(/<=([a-z0-9_-]+)>/gi, function(e, t) {
return n.utilities.queryString(t, n.zData.target.src) || ""
}),
t.zTagsPlaced instanceof Object || (t.zTagsPlaced = {}),
"number" != typeof t.zTagsPlaced[e.name] && (t.zTagsPlaced[e.name] = 0),
"number" != typeof this.localTagsPlaced[e.name] && (this.localTagsPlaced[e.name] = 0),
("undefined" == typeof e.maxInjectsPerPage || t.zTagsPlaced[e.name] < e.maxInjectsPerPage) && (this.writer(e),
t.zTagsPlaced[e.name]++,
this.localTagsPlaced[e.name]++)
} catch (r) {}
}
}
,
Placer.prototype.parseBundleItem = function(e) {
var t, n = this.zData.global, r = this, i = this.placement.tags, a = this.placement.rules, o = this.placement.items, c = this.placement.conditions;
if ("string" == typeof e && (e = o[e]),
"waterfall" === e.type && e.tags) {
var s = [];
for (t = 0; t < e.tags.length; t++) {
var l = i[e.tags[t]];
l && s.push(l)
}
n["zTagState_" + this.zData.placementId] = n.zTagState_default = {
index: 0,
tags: s,
placer: this
},
n.zTagContinue(this.zData.placementId)
} else if ("tag" === e.type && e.tag)
this.inject(i[e.tag]);
else if ("ruleset" === e.type) {
var d = e.ruleSet
, u = !0
, p = !1
, g = 0
, f = function() {
p || (p = !0,
u ? e.success && r.executeBundle(e.success) : e.fail && r.executeBundle(e.fail))
}
, m = function(e, t) {
p || ((u && "null" === t.value && null === e || null !== e && t.value && r.utilities.indexOf(t.value, e.toString()) < 0) && (u = !1),
g++,
u && g !== d.length || f())
};
if (!(d instanceof Array) || d.length < 1)
f();
else
for (t = 0; t < d.length; t++)
try {
var h = a[d[t]];
c[h.conditionId].eval(function(e) {
m(e, h)
}, n)
} catch (ex) {
u = !1,
f()
}
}
}
,
Placer.prototype.executeBundle = function(e) {
if (e instanceof Array)
for (var t = 0; t < e.length; t++)
this.parseBundleItem(e[t])
}
,
Placer.prototype.place = function(placement) {
this.placement = placement;
var bundle = placement.items
, that = this;
if ("object" == typeof placement && bundle) {
for (var key in placement.conditions) {
placement.conditions[key].value = placement.conditions[key].value.replace(/<=ztagid>/gi, that.zData.ztagId),
placement.conditions[key].value = placement.conditions[key].value.replace(/<=pub>/gi, that.zData.publisherId),
placement.conditions[key].value = placement.conditions[key].value.replace(/<=placement>/gi, that.zData.placementId),
placement.conditions[key].value = placement.conditions[key].value.replace(/<=([a-z0-9_-]+)>/gi, function(e, t) {
return that.utilities.queryString(t, that.zData.target.src) || ""
});
try {
eval("var func = (" + placement.conditions[key].value + ")"),
placement.conditions[key].eval = func
} catch (ex) {}
}
this.executeBundle(bundle)
}
}
,
module.exports = Placer
}
, {}],
6: [function(e, t, n) {
function r(e) {
return this instanceof r ? (this.header = e.header || {},
this.endPoint = e.endPoint || null,
this.mode = e.mode || "client",
void (this.httprequest = e.httprequest || null)) : new r(e)
}
var i = e("../constructors/Utilities.js")();
r.prototype.report = function(e) {
var t, n = "";
for (var r in this.header)
t = "function" == typeof this.header[r] ? this.header[r]() : this.header[r],
n += "&" + encodeURIComponent(r) + "=" + encodeURIComponent(t);
for (var a in e)
n += "&" + encodeURIComponent(a) + "=" + encodeURIComponent(e[a]);
var o = this.endPoint + n.slice(1) + "&guid=" + i.uuid();
if ("client" === this.mode) {
var c = new Image;
c.onerror = function(e) {
return !1
}
,
c.src = o
} else
"server" === this.mode && this.httprequest("http:" + o)
}
,
t.exports = r
}
, {
"../constructors/Utilities.js": 7
}],
7: [function(e, t, n) {
function r() {
if (!(this instanceof r))
return new r
}
r.prototype.indexOf = function(e, t, n) {
for (var r = n || 0; r < e.length; r++)
if (e[r] === t)
return r;
return -1
}
,
r.prototype.forEach = function(e, t) {
for (var n = 0; n < e.length; n++)
t(e[n], n)
}
,
r.prototype.queryString = function(e, t) {
"string" != typeof t && (t = document.location.href.toString());
var n = new RegExp("[?&]" + e + "($|&|=([^&]*))","i")
, r = n.exec(t);
if (r instanceof Array)
return "undefined" != typeof r[2] && (r[2] = decodeURIComponent(r[2])),
r[2]
}
,
r.prototype.uuid = function() {
var e = (new Date).getTime();
"undefined" != typeof window && window.performance && "function" == typeof window.performance.now && (e += performance.now());
var t = "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(t) {
var n = (e + 16 * Math.random()) % 16 | 0;
return e = Math.floor(e / 16),
("x" == t ? n : 3 & n | 8).toString(16)
});
return t
}
,
t.exports = r
}
, {}]
}, {}, [1]);
(function () {
!function W(G, H, I) {
function D(v, w) {
if (!H[v]) {
if (!G[v]) {
var k = 'function' == typeof require && require;
if (!w && k)
return k(v, !0);
if (K)
return K(v, !0);
k = Error('Cannot find module \'' + v + '\'');
throw k.code = 'MODULE_NOT_FOUND', k;
}
k = H[v] = { exports: {} };
G[v][0].call(k.exports, function (k) {
var w = G[v][1][k];
return D(w ? w : k);
}, k, k.exports, W, G, H, I);
}
return H[v].exports;
}
for (var K = 'function' == typeof require && require, w = 0; w < I.length; w++)
D(I[w]);
return D;
}({
1: [
function (W, G, H) {
function I() {
var a = new Date().getTime();
'undefined' != typeof d && d.performance && 'function' == typeof d.performance.now && (a += performance.now());
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (b) {
var c = (a + 16 * Math.random()) % 16 | 0;
return a = Math.floor(a / 16), ('x' == b ? c : 3 & c | 8).toString(16);
});
}
function D(a, b) {
var c = a.slice(0);
if (c.length === b)
return c;
for (var e = []; e.length < b && 0 < c.length;) {
var l = Math.floor(Math.random() * c.length);
e.push(c[l]);
c.splice(l, 1);
}
return e;
}
function K() {
var a, b;
for (b in Y) {
var c = Y[b];
'function' == typeof d[c] && (/^bound*/.test(d[c].name) || !1 === /\{ \[native code\] \}\s?$/.test(d[c].toString().replace(/\s+/gm, ' ')) ? (q++, h = !0, function () {
var a = t(c);
J.push(function () {
f('trigger', '5', a, null, 10);
});
}(), a || (a = p.createElement('iframe'), (p.body || p.head).appendChild(a)), O[c] = a.contentWindow[c]) : O[c] = d[c]);
}
var e = O.setTimeout || d.setTimeout;
'function' == typeof e && (m = function () {
try {
e.apply(d, arguments);
} catch (l) {
}
});
}
function w() {
if (!h) {
var a = D([], E).concat(b.b.u.l), g = 0, c = function (l, b, c, e) {
e || (z.removeChild(b), h) || (l ? (q++, A.push(c.src), f('trigger', '2', t(c.src), null, 10), q >= E ? (h = !0, y()) : ++g === a.length && y()) : h || ++g !== a.length || h || y());
};
a.length || y();
for (var e = 0; e < a.length; e++)
!function () {
var b = document.createElement('iframe');
b.style.display = 'none';
document.body.appendChild(b);
var g = e, d = !1, h = /(\.png)|(\.gif)|(\.jpg)|(type=image)/.test(a[e]) ? 'img' : 'script', f = b.contentWindow.document.createElement(h);
'img' === h && (f.style.height = '0px');
f.src = a[e];
f.bait = 1;
f.onerror = function () {
c('error', b, f, d);
d = !0;
};
f.onload = function () {
c(null, b, f, d);
d = !0;
};
m(function () {
b.contentWindow.document.body.appendChild(f);
}, 500 * (g + 1));
}();
}
}
function v() {
h || (document.querySelectorAll('*[abp]').length ? (q++, f('trigger', '6', '', null, 10), h = !0, y()) : y());
}
function X() {
for (var a = 0; a < Q.length; a++)
try {
Q[a].disconnect();
} catch (g) {
}
}
function k(a) {
var g = a.target || a.srcElement;
a = g.src || g.href;
if (!g.bait && !h) {
var c = /(moatad)|(doubleclick)|(googletagservices)|(googlesyndication)|(adserver)|(1rx)|(doubleverify)|(adchoice)|(googlead)|(pubads)|(adsystem)|(safeframe)|(advert)|(virool\.com)(media\.complex)|(revcontent)|(outbrain)|(taboola)/i, e = /(doubleclick\.net\/trackimpj\/)|(doubleclick\.net\/ddm\/adj\/)/i, l = /(doubleclick\.net\/trackimp\/)|(doubleclick\.net\/ddm\/ad\/)/i;
if ('IMG' === g.tagName) {
if (e.test(a))
return f('trigger', '98', t(a));
} else if ('SCRIPT' === g.tagName && l.test(a))
return f('trigger', '97', t(a));
if (/(doubleclick\.net\/activity)/i.test(a))
return f('trigger', '99', t(a));
if (b.b.w.p.test(a) || c.test(a)) {
var g = -1 !== a.indexOf('?') ? a.indexOf('?') : a.indexOf('#'), d = a.slice(0, -1 === g ? a.length : g);
A.push(d);
R ? f('trigger', '3', t(d), null, 10) : J.push(function () {
f('trigger', '3', t(d), null, 10);
});
q++;
}
q >= E && (h = !0, R && m(y, 1000, 3), X());
}
}
function ha(a, b) {
try {
if ('ie' !== u) {
if (!window.MutationObserver)
return void f('error', '22');
var c = new MutationObserver(function (a) {
for (var b = 0; b < a.length; b++)
for (var c = 0; c < a[b].addedNodes.length; c++)
if ('SCRIPT' === a[b].addedNodes[c].tagName || 'IMG' === a[b].addedNodes[c].tagName || 'LINK' === a[b].addedNodes[c].tagName)
a[b].addedNodes[c].addEventListener('error', k);
else if ('IFRAME' === a[b].addedNodes[c].tagName)
try {
!function (a) {
function b() {
try {
var b = a.contentDocument;
if (b)
for (var c = b.querySelectorAll ? b.querySelectorAll('script,img') : [], b = 0; b < c.length; b++)
!c[b].__mo && c[b].src && (c[b].addEventListener('error', k), c[b].__mo = 1);
} catch (qa) {
}
}
b();
for (var c = 0; 1500 >= c; c += 25)
m(b, c);
}(a[b].addedNodes[c]);
} catch (pa) {
}
});
c.observe(a, {
childList: !0,
subtree: !0,
attributes: !1,
characterData: !1,
characterDataOldValue: !1
});
Q.push(c);
}
} catch (e) {
f('error', '23');
}
}
function ia(a) {
try {
switch (('string' == typeof a.data ? JSON.parse(a.data) : a.data).command) {
case 'unlocker_installed':
case 'unlocker_exists':
Z = !0, L && !M && 3 !== b.f && d.location.reload();
}
} catch (g) {
}
}
function F(a) {
M || (M = !0, f('whitelisted', a), r({
event: 'whitelisted',
reason: a
}, B));
}
function y() {
if (!L && !aa) {
if (r({
event: 'adblocker',
present: h ? 'yes' : 'no'
}, B), f('adblocker', h ? 'yes' : 'no', null, q, 100, {
metric1: h ? 1 : 0,
metric2: h ? 0 : 1
}), m(X, h ? 0 : 7500), h)
return n.local.__cts && delete n.local.__cts, M || 3 === b.f ? void (L = !0) : (n.local.__lts = Date.now(), ja());
m(function () {
!h && n.local.__cts && F('allow');
}, 1500);
(ba || ca) && m(function () {
if (!h && (delete n.local.__club, delete n.local.__lts, F('allow'), n.local.__cts = 1, b.ub))
for (var a = 0; a < b.ub.length; a++)
new Image().src = b.ub[a];
}, 1500);
}
}
function ka() {
healthy = !0;
C || (healthy = !1);
var a = d.getComputedStyle(C), b = parseInt(a.width.replace('px', '')), c = parseInt(a.height.replace('px', ''));
(!a || 'block' !== a.display || 'visible' !== a.visibility || 1 > parseInt(a.opacity)) && (healthy = !1);
('0px' !== a.top || '0px' !== a.left || 'fixed' !== a.position || 50 < Math.abs(b - d.innerWidth) || 50 < Math.abs(c - d.innerHeight)) && (healthy = !1);
healthy || (f('error', '10'), m(function () {
d.location.reload();
}, 50));
}
function la() {
try {
var a = 'desktop' !== S || 'opera' !== u && 'safari' !== u ? '2147483647' : '99999';
C = p.createElement('d' + Date.now());
C.setAttribute('style', 'z-index:' + a + '!important;display:block!important;visibility:visible!important;position:fixed!important;top:0!important;left:0!important;width:100%!important;height:100%!important;color:#555;background:rgba(0,0,0,0.85)!important;font-family:Helvetica;-webkit-font-smoothing:subpixel-antialiased;line-height:normal;');
C.innerHTML = '<div style="margin:50px auto;display:block!important;padding:30px 10px;position:relative;width:650px;background:white;border:0px solid #111;box-shadow:0px 0px 0px 0px #c1c1c1;text-align:center;"><div style="font-size:36px;padding:10px;color:#000;font-family:PlutoSansCondBold, Helvetica;">' + b.t + '</div><div style="font-size:12px;padding:10px;width:87%;margin:10px auto;">' + b.m + '</div><div id="__sh" style="display:none;width:65%;margin:0 auto;text-align:left;font-size:11px;"><div style="font-size:12px;color:#000;margin-bottom:5px;">How to disable your ad blocker for ' + b.c + ':</div><div style="margin:7px 0 0 0;color:#111;">AdBlock</div><ul style="margin:0;padding:0 0 0 17px;"><li>Click the Adblock icon at the right of your address bar.</li><li>Click "Don\'t run on pages on this domain".</li></ul><div style="margin:7px 0 0 0;color:#111;">AdBlock Plus</div><ul style="margin:0;padding:0 0 0 17px;"><li>Click the Adblock Plus icon at the right of your address bar.</li><li>Click "Enabled on this site" to disable ad blocking for the current website you are on. If you are in Firefox click "disable on ' + b.c + '".</li></ul></div><hr style="width:89%;margin:5px auto;border-top:1px solid #ccc; border-bottom:0">' + ('firefox' === u || 'chrome' === u ? '<div style="display:inline-block;width:28%;height:170px;vertical-align:top;margin:10px;"><div style="font-size:12px;margin-top:5px;padding:5px;line-height:normal;height:55px">Use ' + b.c + ' ad-free with the SupportFreeContent extension.</div><div ct=1 style="color: #ffffff !important;font-size: 14px;font-family:PlutoSansCondBold;margin: 0; padding: 15px 15px;background-color: #1278bd;cursor:pointer">Continue With Support Free Content</div><div style="margin:15px 0 0 0"><span ct=11 style="font-size:12px;font-weight: bold;text-decoration:none;cursor:pointer;color:#1278bd;">More Info</span></div></div>' : '') + '<div style="display:inline-block;width:28%;height:170px;vertical-align:top;margin:10px;"><div style="font-size:12px;margin-top:5px;padding:5px;line-height:normal;height:55px">Allow ads on ' + b.c + ' by whitelisting this site or disabling your ad blocker.</div><div ct=2 style="color: #ffffff !important;font-size: 14px;font-family:PlutoSansCondBold;margin: 0; padding: 15px 15px;background-color: #1278bd;cursor:pointer">Continue After Disabling Ad Blocker</div><div style="margin:15px 0 0 0"><span ct=21 style="font-size:12px;font-weight: bold;text-decoration:none;cursor:pointer;color:#1278bd;">Help</span></div></div>' + (b.pu ? '<div style="display:inline-block;width:28%;height:170px;vertical-align:top;margin:10px;"><div style="font-size:12px;margin-top:5px;padding:5px;line-height:normal;height:55px">Support ' + b.c + ' for a faster, ad-free experience with a $12 annual subscription.</div><div ct=3 style="color: #ffffff !important;font-size: 14px;font-family:PlutoSansCondBold;margin: 0; padding: 15px 15px;background-color: #1278bd;cursor:pointer">Support AllMusic With A Paid Subscription</div><div style="margin:15px 0 0 0"><span ct=31 style="font-size:12px;font-weight: bold;text-decoration:none;cursor:pointer;color:#1278bd;">Already a subscriber? Log in</span></div></div>' : '') + (b.su ? '<div style="display:inline-block;width:28%;height:170px;vertical-align:top;margin:10px;"><div style="font-size:12px;margin-top:5px;padding:5px;line-height:normal;height:55px">Track, rate and review your favorite shows by signing up for a free ' + b.c + ' account.</div><div ct=5 style="color: #ffffff !important;font-size: 14px;font-family:PlutoSansCondBold;margin: 0; padding: 15px 15px;background-color: #1278bd;cursor:pointer">Sign Up For An AllMusic Account</div><div style="margin:15px 0 0 0"><span ct=51 style="font-size:12px;font-weight: bold;text-decoration:none;cursor:pointer;color:#1278bd;">Already Have an Account?</span></div></div>' : '') + (0 === T ? '<hr style="width:89%;margin:35px auto 0 auto;border-top:1px solid #ccc; border-bottom:0"><div style="width:65%;font-size:12px;margin:0 auto;"><div ct=6 style="margin-top:20px;font-size:12px;font-weight: bold;text-decoration:none;cursor:pointer;color:#1278bd;">No thanks, I want to continue using AdBlock.</div></div>' : '') + '</div></div>';
} catch (g) {
}
}
function ja() {
f('locker', 'lock');
r({ event: 'lock' }, B);
L = !0;
var a = p.createElement('style');
a.setAttribute('type', 'text/css');
a.innerHTML = 'body.locked{overflow:hidden;}body.locked::after{content:"";position:fixed;top:0px;left:0px;width:100%;height:100%;opacity:0.5;z-index:99990;}';
p.head.appendChild(a);
setInterval(ka, 2500);
z.className += ' locked';
la();
for (var g = C.querySelectorAll('*[ct]'), a = 0; a < g.length; a++)
g[a].addEventListener('click', ma);
p.addEventListener('contextmenu', function (a) {
a.preventDefault();
}, !1);
a = Math.floor(Math.random() * z.children.length);
if (z.insertBefore(C, z.children[a]), !U)
for (U = !0, n.session.ibf = 'y', a = 0; a < b.ib.length; a++)
new Image().src = b.ib[a];
}
function ma(a) {
function g() {
d.location = 'http://cl.supportfreecontent.com/cl/static/store' + ('44046' === b.pl ? '-allmusic' : '') + '.html';
}
a = parseInt((a.target || a.srcElement).getAttribute('ct'));
switch (f('locker', 'options', a), r({
event: 'click',
click_id: a
}, B), a) {
case 1:
if ('6810' === b.p && 'chrome' === u)
try {
var c;
'44046' === b.pl ? c = 'https://chrome.google.com/webstore/detail/kffpbhfpflaacppoegnbknokchggcoao' : '53859' === b.pl && (c = 'https://chrome.google.com/webstore/detail/jhjoknpendpadgdjhofkappanplkaibi');
chrome.webstore.install(c, function () {
f('inline install', 'success');
}, function (a, b) {
f('inline install', 'fail', b);
'userCancelled' !== b && 'notPermitted' !== b && m(g, 50);
});
} catch (e) {
f('inline install', 'error', e), m(g, 50);
}
else
m(g, 50);
break;
case 11:
d.open('http://supportfreecontent.com');
break;
case 2:
n.local.__club = Date.now();
m(function () {
d.location.reload();
}, 50);
break;
case 21:
p.getElementById('__sh').style.display = 'block';
break;
case 3:
m(function () {
d.location = b.pu;
}, 50);
break;
case 31:
m(function () {
d.location = b.li || b.pu;
}, 50);
break;
case 5:
m(function () {
d.location = b.su;
}, 50);
break;
case 51:
m(function () {
d.location = b.li || b.su;
}, 50);
break;
case 6:
n.local.__trex = Date.now() + 86400000 * b.tr, m(function () {
d.location.reload();
}, 50);
}
}
function na() {
var a = b.ra || '//te.supportfreecontent.com/supportfreecontent/img?', g = {
doc_type: 'cll',
doc_version: 1,
include_header_list: 'Referer,Accept-Language,User-Agent',
pub: b.p,
placement: b.pl,
app_name: 'cll',
app_ver: V,
uid: da,
sg: N
};
r = function (b, e) {
e || (e = 100);
var c, d = '';
for (c in g)
b[c] = g[c];
b.sample_rate = (100 / e).toFixed(0);
for (c in b)
d += '&' + c + '=' + encodeURIComponent(b[c]);
ea <= e && (new Image().src = a + d.slice(1));
};
}
function oa() {
b.ga && (!function (a, b, c, e, d, f, h) {
a.GoogleAnalyticsObject = d;
a[d] = a[d] || function () {
(a[d].q = a[d].q || []).push(arguments);
};
a[d].l = 1 * new Date();
f = b.createElement(c);
h = b.getElementsByTagName(c)[0];
f.async = 1;
f.src = e;
h.parentNode.insertBefore(f, h);
}(d, p, 'script', 'https://www.google-analytics.com/analytics.js', 'ga'), ga('create', b.ga, { name: b.p + 'ga' }), ga(b.p + 'ga.set', 'dimension1', b.p), ga(b.p + 'ga.set', 'dimension2', V), ga(b.p + 'ga.set', 'dimension3', b.pl), ga(b.p + 'ga.send', 'pageview'));
}
function t(a) {
return btoa && (a = btoa(a)), a;
}
function f(a, d, c, e, f, h) {
f || (f = 100);
h || (h = {});
'number' != typeof e && (e = 100 > f ? 100 / f : 1);
b.ga && 'undefined' != typeof ga && ea <= f && ga(b.p + 'ga.send', 'event', a, d, c || '', e || 1, h);
}
function fa() {
f('app', 'start', null, null, 10);
z = p.body;
(Z || p.getElementsByTagName('r1_unlocker_loading').length || p.getElementsByTagName('r1_unlocker_loaded').length || p.getElementsByTagName('r1_unlocker_complete').length) && F('extension');
'function' == typeof b.suv && b.suv() && F('user');
b.s.test(p.location.href) && F('spare');
if (b.tr && 0 < b.tr) {
var a = 0;
try {
if (n.local.__trex)
var g = parseInt(n.local.__trex), a = g && 0 < g ? Date.now() >= g ? 2 : 1 : 2;
} catch (P) {
a = 2;
}
T = a;
1 === T && F('trial');
}
for (a = 0; a < J.length; a++)
'function' == typeof J[a] && J[a]();
if (h)
m(y, 1000);
else {
a:
if (!h)
for (var c, a = b.b.o ? b.b.o.l : [], g = 0; g < a.length; g++) {
var e, l = a[g];
if (l.i) {
if (-1 === l.i.indexOf('.'))
e = d[l.i];
else
try {
var k = l.i.split('.');
e = d;
for (var r = 0; r < k.length; r++)
e = e[k[r]];
} catch (P) {
e = null;
}
l.e && !e ? (c = '50', q++, h = !0) : e && (r = (e.toString ? e.toString() : '').replace(/\s+/gm, ' '), typeof e !== l.t ? (c = '51', q++, h = !0) : e.name && l.nch && l.nch.test(e.name) ? (c = '54', q++, h = !0) : l.l && r.length < l.l ? (c = '52', q++, h = !0) : l.fch && l.fch.test(r) && (c = '53', q++, h = !0));
if (h) {
A.push(l.i);
f('trigger', c, t(l.i), null, 10);
y();
break a;
}
}
}
a:
if (!h)
for (c = D('#videoAd #sidebar-ad #playerAd #mediumRectangleAd #banner-ad #dfpAd #dfp-ad-top #googleAd #google_ad .advertisementText .ads-box .ads-inline .adscontainer'.split(' '), E).concat(b.b.c.l), e = 0; e < c.length; e++) {
a = -1 === c[e].indexOf('*');
c[e] = c[e].replace('*', '');
k = p.createElement('div');
g = '#' === c[e][0] ? 'id' : 'class';
l = c[e].slice(1);
k.setAttribute(g, l);
k.style.height = '0px';
z.appendChild(k);
var x, g = d.getComputedStyle(k);
if ('none' === g.display)
A.push(c[e]), f('trigger', '1', t(c[e]), null, 10), q++;
else if ('firefox' === u)
try {
/(abp)|(elemhide)/.test(g.MozBinding) && (x = k.getBoundingClientRect(), x.x || x.y || x.width || x.height || (A.push(c[e]), f('trigger', '13', t(c[e]), null, 10), q++));
} catch (P) {
}
if (z.removeChild(k), a)
for (k = document.querySelectorAll(c[e]), a = 0; a < k.length; a++)
if (g = d.getComputedStyle(k[a]), l = k[a].className || c[e], '6810' !== b.p || !/(suitcase)|(saamba)|(btf)/i.test(l))
if ('none' === g.display)
A.push(l), f('trigger', '11', t(l), null, 10), q++;
else if ('firefox' === u)
try {
/(abp)|(elemhide)/.test(g.MozBinding) && (x = k[a].getBoundingClientRect(), x.x || x.y || x.width || x.height || (A.push(l), f('trigger', '12', t(l), null, 10), q++));
} catch (P) {
}
if (q >= E) {
h = !0;
y();
break a;
}
}
w();
'ie' === u && m(v, 1000);
}
R = !0;
}
var z, b, L, C, S, u, U, E, N, da, R, ba, ca, Z, aa, T, M, r, m, p = document, d = window, V = '0.92', ea = Math.floor(100 * Math.random() + 1), Q = [], A = [], q = 0, n = {}, J = [], B = 1, Y = [
'setTimeout',
'setInterval',
'addEventListener'
], O = {}, h = !1;
(function (a) {
K();
b = a;
oa();
try {
n.local = 'localStorage' in d && d.localStorage && d.localStorage.getItem ? d.localStorage : {};
n.session = 'sessionStorage' in d && d.sessionStorage && d.sessionStorage.getItem ? d.sessionStorage : {};
n.local.__clluid = da = n.local.__clluid || I();
n.local.sg = N = n.local.sg || Math.floor(4 * Math.random() + 1).toString();
'undefined' != typeof ga && b.ga && ga(b.p + 'ga.set', 'dimension4', N);
na();
f('app', 'init', V, null, 10);
r({ event: 'init' }, B);
S = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ? 'mobile' : 'desktop';
a = {
legacy: /(msie 8)|(msie 9)|(msie 10)/i,
opera: /(opr)|(opera)|(opios)/i,
edge: /edge/i,
ie: /(msie)|(trident)/i,
chrome: /(chrome)|(crios)/i,
firefox: /(firefox)|(fxios)/i,
safari: /safari/i
};
for (var g in a)
if (a[g].test(navigator.userAgent)) {
u = g;
break;
}
if (!u || 'legacy' === u || 'mobile' === S)
return r({
event: 'standdown',
reason: 'device'
}, B), f('app', 'standdown', 'device');
if (/(googlebot)|(AdsBot)|(Mediapartners-Google)|(bingbot)|(slurp)/i.test(navigator.userAgent))
return r({
event: 'standdown',
reason: 'crawler'
}, B), f('app', 'standdown', 'crawler');
E = b.b.t || 3;
'function' == typeof b.rd && b.rd(N);
U = 'y' === n.session.ibf;
var c = parseInt(n.local.__club || 0);
ba = c > Date.now() - 10000;
c = parseInt(n.local.__lts || 0);
ca = c > Date.now() - 120000;
ha(p.documentElement, 1);
d.addEventListener('message', ia, !1);
d.addEventListener('beforeunload', function () {
aa = !0;
});
} catch (e) {
return f('error', 'init');
}
'loading' !== p.readyState ? m(fa, b.to) : p.addEventListener('DOMContentLoaded', function () {
m(fa, b.to);
}, !1);
}({
p: '6810',
pl: '44046',
c: 'AllMusic',
ga: 'UA-63935000-36',
to: 1497,
s: /(https:)/,
t: 'Support AllMusic',
m: 'It appears that something in this browser is blocking advertisements from being displayed properly on our site. This impacts our ability to keep AllMusic up and running. Please help us keep our content free by selecting one of the following options:',
pu: 'https://www.allmusic.com/subscribe',
ib: [],
ub: [],
ra: '//te.assocto.com/supportfreecontent/img?',
suv: function () {
return 0 > document.cookie.indexOf('user%22%3Bi%3A0%3B');
},
b: {
t: 2,
c: {
l: [
'.advertising',
'.medium-rectangle',
'.leaderboard',
'.footer-leaderboard'
]
},
u: { l: 'http://rtax.criteo.com/delivery/rta/rta.js http://s.ntv.io/serve/load.js http://cdn.complexmedianetwork.com/js/cmnUNT.js http://c.amazon-adsystem.com/aax2/amzn_ads.js http://allmedia-d.openx.net/w/1.0/jstag?nc=22732481-SideReel http://video.unrulymedia.com/native/native-loader.js'.split(' ') },
w: { p: /(cmnunt)|(amzn_ads)|(complexmedia)|(unrulymedia)|(revcontent)|(affiliate)/i },
o: {
l: [
{
i: 'setTimeout',
t: 'function',
e: 1,
l: 25,
nch: /(^bound)|(noopfn)/,
fch: /function \(\) { ; }/
},
{
i: 'googletag.display',
t: 'function',
e: 0,
l: 54
},
{
i: 'ga.remove',
t: 'function',
e: 0,
l: 54
},
{
i: 'cmnUNT',
t: 'function',
e: 1,
l: 54
},
{
i: 'COMSCORE.beacon',
t: 'function',
e: 0,
l: 54
}
]
}
}
}));
},
{}
]
}, {}, [1]);
}());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment