This solution will allow multiple BK-CoreTags to run on the same page by utilising a queueing system.
Notes:
/*!
bktag - v3.1.4_custom_1 - roshan.gonsalkorale@oracle.com 2020 04 23
- Search "CUSTOM MODIFIED CODE" for modifications
bktag - v3.1.4 - 20200212;
Copyright (c) 1998, 2020, Oracle and/or its affiliates.
*/
/*!
@babel/runtime : 7.4.5
MIT License
Copyright (c) 2014-present Sebastian McKenzie and other contributors
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
object-assign : 4.1.0
The MIT License (MIT)
Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
crypto-js : 3.1.9-1
# License
[The MIT License (MIT)](http://opensource.org/licenses/MIT)
Copyright (c) 2009-2013 Jeff Mott
Copyright (c) 2013-2016 Evan Vosberg
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
var tags = function(e) {
var t = {};
function n(i) {
if (t[i]) return t[i].exports;
var r = t[i] = {
i: i,
l: !1,
exports: {}
};
return e[i].call(r.exports, r, r.exports, n), r.l = !0, r.exports
}
return n.m = e, n.c = t, n.d = function(e, t, i) {
n.o(e, t) || Object.defineProperty(e, t, {
enumerable: !0,
get: i
})
}, n.r = function(e) {
"undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(e, Symbol.toStringTag, {
value: "Module"
}), Object.defineProperty(e, "__esModule", {
value: !0
})
}, n.t = function(e, t) {
if (1 & t && (e = n(e)), 8 & t) return e;
if (4 & t && "object" == typeof e && e && e.__esModule) return e;
var i = Object.create(null);
if (n.r(i), Object.defineProperty(i, "default", {
enumerable: !0,
value: e
}), 2 & t && "string" != typeof e)
for (var r in e) n.d(i, r, function(t) {
return e[t]
}.bind(null, r));
return i
}, n.n = function(e) {
var t = e && e.__esModule ? function() {
return e.default
} : function() {
return e
};
return n.d(t, "a", t), t
}, n.o = function(e, t) {
return Object.prototype.hasOwnProperty.call(e, t)
}, n.p = "", n(n.s = 37)
}({
3: function(e, t) {
function n(e) {
return (n = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
return typeof e
} : function(e) {
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e
})(e)
}
function i(t) {
return "function" == typeof Symbol && "symbol" === n(Symbol.iterator) ? e.exports = i = function(e) {
return n(e)
} : e.exports = i = function(e) {
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : n(e)
}, i(t)
}
e.exports = i
},
37: function(e, t, n) {
"use strict";
function i(e, t, n) {
var i = new Date,
r = n ? i.getTime() + 864e5 * n : i.getTime(),
o = [];
i.setTime(r), o.push(e), o.push("="), o.push(t), o.push(n ? "; expires=".concat(i.toUTCString()) : ""), o.push("; path=/"), document.cookie = o.join("")
}
function r(e) {
for (var t = "".concat(e, "="), n = document.cookie.split(";"), i = "", r = null, o = n.length - 1; o >= 0; o -= 1) {
for (i = n[o];
" " === i.charAt(0);) i = i.slice(1);
if (0 === i.indexOf(t)) {
r = i.slice(t.length);
break
}
}
return r
}
n.r(t);
var o = [];
function a(e, t, n) {
var i = t;
if (void 0 !== window.varMap && window.varMap[t] && (i = window.varMap[t]), void 0 !== n) {
var r = "".concat(i, "=").concat(n);
o.push("".concat(e, "=").concat(encodeURIComponent(r)))
} else o.push("".concat(e, "=").concat(i));
return window.BKTAG
}
function s() {
o = []
}
function c(e, t) {
return "string" == typeof e && "string" == typeof t ? a("phint", "__bk_".concat(e), t) : Object.keys(e).forEach(function(t) {
"string" == typeof e[t] && a("phint", "__bk_".concat(t), e[t])
}), window.BKTAG
}
var d = n(7),
u = n.n(d),
l = n(8),
f = n.n(l);
function p() {
for (var e = window.document.getElementsByTagName("meta"), t = [], n = 0; n < e.length; n += 1) e[n].name && "keywords" === e[n].name.toLowerCase() && "" !== e[n].content && t.push(e[n].content);
return t.join(",")
}
function m(e) {
for (var t = document.getElementsByTagName("meta"), n = 0; n < t.length; n += 1) {
var i = t[n];
if (i.name.toLowerCase() === e.toLowerCase() && "" !== i.content) return i.content
}
return null
}
function w() {
return void 0 !== window.location && void 0 !== window.location.search && -1 !== window.location.search.indexOf("debug=1")
}
function h(e, t, n) {
e.addEventListener ? e.addEventListener(t, n, !1) : e.attachEvent("on".concat(t), function(t) {
return n.call(e, t)
})
}
function v(e) {
var t = e.trim().toLowerCase(),
n = t.split("@"),
i = n.shift();
return i.indexOf("+") > -1 && (i = i.substr(0, i.indexOf("+"))), t = "".concat(i, "@").concat(n.shift())
}
function g(e) {
return e.trim().replace(/^[0]+/g, "").replace(/\D/g, "")
}
function b(e, t, n) {
return a("phint", e, n && "" !== n ? f()(n) : ""), a("phint", t, n && "" !== n ? u()(n) : ""), window.BKTAG
}
function y(e) {
Array.isArray(e) ? e.forEach(function(e) {
void 0 !== window[e] && "" !== e && "" !== window[e] && a("phint", e, window[e])
}) : Object.keys(e).forEach(function(t) {
"string" != typeof t || "string" != typeof e[t] && "number" != typeof e[t] && "boolean" != typeof e[t] || a("phint", t, e[t])
})
}
var _ = n(5),
k = n.n(_);
function x(e) {
var t = document.createElement("iframe");
return t.setAttribute("name", e), t.setAttribute("id", e), t.setAttribute("title", "bk"), t.style.border = "0px", t.style.width = "0px", t.style.height = "0px", t.style.display = "none", t.style.position = "absolute", t.style.clip = "rect(0px 0px 0px 0px)", "function" == typeof window.bk_frameLoad && (t.onload = window.bk_frameLoad), t.src = "about:blank", t
}
var T = (Object.assign || k.a)({}, {
site: "site_id",
limit: "pixel_limit",
excludeBkParams: "ignore_meta",
excludeTitle: "exclude_title",
excludeKeywords: "exclude_keywords",
excludeReferrer: "exclude_referrer",
excludeLocation: "exclude_location",
excludeVersion: "exclude_version",
partnerID: "partner_id",
allowMultipleCalls: "allow_multiple_calls",
suppressMultipleCalls: "suppress_multiple_calls",
callback: "callback",
useImage: "use_image",
useMultipleIframes: "use_multiple_iframes",
allData: "all_data",
timeOut: "timeout",
ignoreOutsideIframe: "ignore_outside_iframe",
eventScheduling: "event_scheduling",
suppressEventScheduling: "suppress_event_scheduling",
suppressCacheBusting: "suppress_cache_busting",
pixelUrl: "pixel_url",
pixelSecure: "pixel_secure"
}, {
useFirstParty: "use_first_party",
suppressFirstParty: "suppress_first_party",
sendStatidPayload: "send_statid_payload",
suppressStatidPayload: "suppress_statid_payload"
}, {
metaVars: "meta_vars",
jsList: "js_list",
paramList: "param_list",
useMobile: "use_mobile",
disableMobile: "disable_mobile",
isDebug: "is_debug",
limitGetLength: "limit_get_length"
}),
B = {
2607: 1,
2834: 1,
2894: 1,
3316: 1,
3317: 1,
3318: 1,
3319: 1,
3321: 1,
3322: 1,
3323: 1,
3324: 1,
3325: 1,
3326: 1,
3327: 1,
3328: 1,
3329: 1,
3330: 1,
3331: 1,
3332: 1,
3333: 1,
3334: 1,
3338: 1,
3339: 1,
3340: 1,
3341: 1,
3344: 1,
3345: 1,
3346: 1,
3348: 1
},
C = !1;
var O = "https://stags.bluekai.com/";
var S = function(e) {
var t = {};
return Object.keys(e).forEach(function(n) {
void 0 !== window["bk_".concat(e[n])] && (t[n] = window["bk_".concat(e[n])])
}), t
},
A = null;
var E = n(3),
j = n.n(E),
P = function(e, t) {
var n = {};
return "object" === j()(e) && Object.keys(t).forEach(function(i) {
void 0 !== e[t[i]] && (n[i] = e[t[i]])
}), n
},
I = Object.assign || k.a,
D = 2e3;
function K(e) {
var t = BKTAG.getReadyState();
if (void 0 === t) {
! function t() {
document.body ? e() : setTimeout(t, 100)
}()
} else "complete" !== t && window.addEventListener ? window.addEventListener("load", e) : e()
}
var G = function(e) {
for (var t = {}, n = e.split(","), i = 0; i < n.length; i += 1) t[n[i]] = !0;
return t
};
var M = /^<(\w+)((?:\s+\w+(?:\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/,
H = /^<\/(\w+)[^>]*>/,
N = /(\w+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))?/g,
L = G("area,base,basefont,br,col,frame,hr,img,input,isindex,link,meta,param,embed"),
V = G("address,applet,blockquote,button,center,dd,del,dir,div,dl,dt,fieldset,form,frameset,hr,iframe,ins,isindex,li,map,menu,noframes,noscript,NOSCRIPT,object,ol,p,pre,script,SCRIPT,table,tbody,td,tfoot,th,thead,tr,ul"),
R = G("a,abbr,acronym,applet,b,basefont,bdo,big,br,button,cite,code,del,dfn,em,font,i,iframe,img,input,ins,kbd,label,map,object,q,s,samp,script,SCRIPT,select,small,span,strike,strong,sub,sup,textarea,tt,u,var"),
U = G("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr"),
J = G("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected"),
F = G("script,SCRIPT,style"),
z = G("html,head,body,title"),
W = {
link: "head",
base: "head"
};
function q(e, t) {
for (var n = t.split("."), i = e, r = 0; r < n.length; r += 1) void 0 === i[n[r]] && (i[n[r]] = {}), i = i[n[r]];
return i
}
var $ = /^\d+$/,
X = ["prop", "eVar", "list"];
function Q(e, t) {
var n;
return void 0 === t ? X.forEach(function(t) {
0 === e.indexOf(t) && (n = e.split(t))
}) : 0 === e.indexOf(t) && (n = e.split(t)), void 0 !== n && (void 0 === n || 2 === n.length) && (void 0 === n || !0 === $.test(n[1]))
}
function Y(e) {
var t = {};
if (void 0 !== window) {
var n = ee();
void 0 !== n && void 0 !== n.version && Object.keys(n).forEach(function(i) {
Q(i, e) && (t[i] = n[i])
})
}
return t
}
function Z() {
var e = window.s;
if (void 0 !== e && "object" === j()(e) && void 0 !== e.version) return window.s;
var t = window._satellite;
if (void 0 !== t && void 0 !== t.buildDate) {
var n = t.getToolsByType;
if (void 0 !== n && "function" == typeof n) {
var i = n("sc");
if (Array.isArray(i) && i.length > 0) {
var r = i[0];
if (void 0 !== r && "function" == typeof r.getS) return r.getS()
}
}
}
}
function ee() {
if (void 0 !== window) {
if (void 0 !== window.s && void 0 !== window.s.version) return window.s;
if (void 0 !== window.s_Obj && void 0 !== window.s_Obj.version) return window.s_Obj;
if (void 0 !== window._satellite) {
var e = Z();
if (void 0 !== e && void 0 !== e.version) return e
}
}
}
function te() {
var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : [],
t = {};
return e.forEach(function(e) {
if (void 0 !== e && Q(e)) return !1;
var n = ee();
void 0 !== n && void 0 !== n[e] && (t[e] = n[e])
}), t
}
function ne(e) {
Object.keys(e).forEach(function(e) {
if (void 0 !== window) {
var t = ee();
void 0 !== t && void 0 !== t[e] && a("phint", "".concat(e), t[e])
}
}.bind(e))
}
function ie(e, t) {
var n = function() {
var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {},
t = arguments.length > 1 ? arguments[1] : void 0,
n = e.reportSuiteID,
i = e.marketingCloudContainerID,
r = e.analyticsVisitorContainerID,
o = e.extraProps,
a = "object" === j()(t) ? t : Z();
if (void 0 !== n && void 0 !== a) return {
reportSuiteID: n || a.account,
sVersion: a.version || "X",
marketingCloudContainerID: i,
marketingCloudVisitorID: a.marketingCloudVisitorID,
analyticsVisitorContainerID: r,
analyticsVisitorID: a.analyticsVisitorID,
extraProps: o,
extraPropsContainer: te(o),
prop: Y("prop"),
eVar: Y("eVar"),
list: Y("list")
}
}(e, t);
void 0 !== n && (a("phint", "rsid", n.reportSuiteID), a("phint", "sv", n.sVersion), a("phint", "mccid", n.marketingCloudContainerID), a("phint", "mcvid", n.marketingCloudVisitorID), a("phint", "avcid", n.analyticsVisitorContainerID), a("phint", "avid", n.analyticsVisitorID), void 0 !== window && [n.prop, n.eVar, n.list, n.extraPropsContainer].forEach(ne))
}
var re = {
addParam: a,
addBkParam: c,
addHash: b,
addEmailHash: function(e) {
var t = e;
return t ? "string" != typeof t && (t = t.toString()) : t = "", b("e_id_m", "e_id_s", t = v(t))
},
addPhoneHash: function(e) {
var t = e;
return t ? "string" != typeof t && (t = t.toString()) : t = "", b("p_id_m", "p_id_s", t = g(t))
},
readCookie: r,
createCookie: i,
eraseCookie: function(e) {
e && i(e, "", -1)
},
getGlobals: y,
getReadyState: function() {
return document.readyState
},
_dest: null,
_reset: function() {
return C = !1, s(), Object.keys(T).forEach(function(e) {
var t = "bk_".concat(T[e]);
try {
delete window[t]
} catch (e) {
window[t] = void 0
}
}), window.BKTAG
},
doTag: function(e, t, n, d, u, l, f, v, g) {
var b = I({
site: e,
limit: t,
excludeBkParams: n,
partnerID: d,
allowMultipleCalls: u,
callback: l,
allData: f,
timeOut: v,
ignoreOutsideIframe: g
}, S(T), P(e, T)),
_ = o;
if (!(!0 === b.suppressMultipleCalls || C && !0 !== b.allowMultipleCalls)) {
C = !0, void 0 === b.timeOut && (b.timeOut = 1e3), _.unshift("ret=".concat(b.callback ? "js" : "html"));
var k = !(void 0 === b.partnerID || null === b.partnerID);
if (k && _.unshift("partner=".concat(encodeURIComponent(b.partnerID))), b.excludeBkParams || b.excludeTitle || "" !== document.title && c("t", document.title), b.excludeBkParams || b.excludeKeywords || c("k", p()), !b.excludeBkParams && !b.excludeReferrer && "referrer" in window.document && "" !== window.document.referrer) {
var E = window.document.referrer,
j = E.indexOf("tags.bluekai.com");
c("pr", j >= 0 ? E.substr(0, j + "tags.bluekai.com".length) : E)
}
if (b.excludeBkParams || b.excludeLocation || c("l", window.location.toString()), b.excludeBkParams || b.excludeVersion || c("v", "3.1.4"), b.callback ? a("jscb", encodeURIComponent(b.callback)) : void 0 !== b.limit && a("limit", encodeURIComponent(b.limit)), !0 === b.allData && a("data", "all"), !0 !== b.suppressEventScheduling && !0 === b.eventScheduling && h("message", function(e) {
if ("http://tags.bluekai.com" === e.origin) {
var t = document.getElementById("__bkframe"),
n = JSON.parse(e.data);
if (n.status && "loaded" === n.status && t.contentWindow.postMessage(JSON.stringify({
get: "events"
}), "*"), n.scheduled) {
var i = JSON.parse(n.scheduled);
i.forEach(function(e) {
var n;
("window" === i[e] ? window : document.getElementById(i[e])).addEventListener(e, (n = e, function() {
t.contentWindow.postMessage(JSON.stringify({
event: n
}), "*"), t.contentWindow.postMessage(JSON.stringify({
schedule: "run"
}), "*")
}), !1)
})
}
n.status && "complete" === n.status && t.contentWindow.postMessage(JSON.stringify({
status: "ack"
}), "*")
}
}, !1), !0 !== b.suppressFirstParty && b.useFirstParty && (r("bkrid") || i("bkrid", Math.floor(2147483648 * Math.random()), 180), r("bkrid") && a("bkrid", encodeURIComponent(r("bkrid")))), (w() || b.isDebug) && a("debug", "1"), b.excludeBkParams || void 0 === b.paramList || y(b.paramList), b.excludeBkParams || void 0 === b.jsList || y(b.jsList), !b.excludeBkParams && void 0 !== b.metaVars)
for (var G = 0; G < b.metaVars.length; G += 1) {
var M = m(b.metaVars[G]);
null !== M && c(b.metaVars[G], M)
}!0 !== b.suppressCacheBusting && a("r", parseInt(99999999 * Math.random(), 10));
var H, N = "".concat(function(e) {
if (void 0 !== e) {
if ("https:" === window.document.location.protocol && e.pixelSecure) return e.pixelSecure;
if (e.pixelUrl) return e.pixelUrl
}
return O
}(b)).concat(k ? "psite" : "site", "/").concat(b.site),
L = "".concat(N, "?").concat(_.join("&"));
if (b.limitGetLength && (L = L.substr(0, D)), A = H = L, window.BKTAG._dest = H, b.callback) {
var V = A;
if (b.useImage) {
var R = document.createElement("span");
R.style.display = "none", K(function() {
document.getElementsByTagName("body")[0].appendChild(R);
var e = document.createElement("img");
e.src = V, R.appendChild(e)
})
} else {
var U = document.createElement("script");
U.type = "text/javascript", U.src = V, U.id = "__bk_script__", B["".concat(e)] && setTimeout(function() {
var e = document.getElementById("__bk_script__");
e && (e.removeNode ? e.removeNode(!0) : e.parentNode.removeChild(U))
}, b.timeOut), K(function() {
return document.getElementsByTagName("head")[0].appendChild(U)
})
}
} else if (function(e) {
var t = "__bkframe";
if (void 0 === window.frames[t] || void 0 === window.document.getElementById(t)) {
var n = x(t),
i = window.document.getElementsByTagName("body")[0];
i && i.appendChild(n)
}
"function" == typeof e && e()
}(function() {
if (b.useMultipleIframes) {
var e = x("__bkframe_".concat(b.site, "_").concat((new Date).valueOf()));
e.className = "__bkframe_site_".concat(b.site), e.src = L, K(function() {
return document.getElementsByTagName("body")[0].appendChild(e)
})
} else if (window.frames && window.frames.__bkframe) window.frames.__bkframe.location.replace(L);
else {
var t = x("__bkframe");
K(function() {
document.getElementsByTagName("body")[0].appendChild(t), window.frames.__bkframe.location.replace(L)
})
}
}), _.shift(), void 0 !== b.ignoreOutsideIframe && !1 === b.ignoreOutsideIframe) {
_.unshift("ret=jsht"), L = (L = "".concat(N, "?").concat(_.join("&"))).substr(0, D);
var J = document.createElement("script");
J.src = L, J.type = "text/javascript", K(function() {
return document.getElementsByTagName("body")[0].appendChild(J)
})
}
"function" == typeof t && t(), s()
}
},
version: "3.1.4",
getTracker: function(e) {
ie(e)
}
};
void 0 === window.BKTAG && q(window, "BKTAG"), window.BKTAG.ns = q, Object.keys(re).forEach(function(e) {
window.BKTAG[e] = re[e]
}), window.BKTAG.addCtxParam = function(e, t) {
return a("phint", e, t), window.BKTAG
}, window.BKTAG.addBkParam = function(e, t) {
return a("phint", "__bk_".concat(e), t), window.BKTAG
}, window.bk_addUserCtx = function(e, t) {
return a("phint", e, t), window.BKTAG
}, window.BKTAG.addPageCtx = window.bk_addUserCtx, window.bk_addPageCtx = window.bk_addUserCtx, window.BKTAG.addUserCtx = window.bk_addUserCtx, window.bk_addEmailHash = function(e) {
return window.BKTAG.addEmailHash(e), window.BKTAG
}, window.bk_addPhoneHash = function(e) {
return window.BKTAG.addPhoneHash(e), window.BKTAG
}, window.bk_doJSTag = function(e, t, n) {
window.BKTAG.doTag(e, t, !1, null, n)
}, window.BKTAG.doJSTag = window.bk_doJSTag, window.bk_doJSTag2 = function(e, t) {
window.BKTAG.doTag(e, t)
}, window.BKTAG.doJSTag2 = window.bk_doJSTag2, window.bk_doCarsJSTag = function(e, t) {
window.BKTAG.doTag(e, t, !0)
}, window.BKTAG.doCarsJSTag = window.bk_doCarsJSTag, window.bk_doPartnerAltTag = function(e, t, n) {
var i = n;
null == n && (i = 0), window.BKTAG.doTag(e, t, !1, i)
}, window.BKTAG.doPartnerAltTag = window.bk_doPartnerAltTag, window.bk_doCallbackTag = function(e, t, n, i) {
window.BKTAG.doTag(e, 0, !1, null, n, t, i)
}, window.BKTAG.doCallbackTag = window.bk_doCallbackTag, window.bk_doCallbackTagWithTimeOut = function(e, t, n, i, r) {
window.BKTAG.doTag(e, 0, !1, null, n, t, i, r)
}, window.BKTAG.doCallbackTagWithTimeOut = window.bk_doCallbackTagWithTimeOut, window.BKTAG.sendData = function(e) {
window.BKTAG.doTag(e)
}, window.BKTAG.htmlToDom = function(e, t) {
var n = [];
if (!(t.documentElement || t.getOwnerDocument && t.getOwnerDocument() || t) && t.createElement && function() {
var e = t.createElement("html"),
n = t.createElement("head");
n.appendChild(t.createElement("title")), e.appendChild(n), e.appendChild(t.createElement("body")), t.appendChild(e)
}(), t.getElementsByTagName)
for (var i in z) z[i] = t.getElementsByTagName(i)[0];
var r = z.body;
! function(e, t) {
var n, i, r, o = [],
a = e;
for (o.last = function() {
return this[this.length - 1]
}; e;) {
if (i = !0, e = e.replace(/^\s+/, ""), o.last() && F[o.last()]) {
var s = new RegExp("</" + o.last() + ">", "i");
n = e.search(s);
var c = e.substring(0, n);
c.length > 0 && (t.chars && t.chars(c), e = e.replace(c, "")), e = e.replace(s, ""), l(0, o.last())
} else if (0 === e.indexOf("\x3c!--") ? (n = e.indexOf("--\x3e")) >= 0 && (t.comment && t.comment(e.substring(4, n)), e = e.substring(n + 3), i = !1) : 0 === e.indexOf("</") ? (r = e.match(H)) && (e = e.substring(r[0].length), r[0].replace(H, l), i = !1) : 0 === e.indexOf("<") && (r = e.match(M)) && (e = e.substring(r[0].length), r[0].replace(M, u), i = !1), i) {
var d = (n = e.indexOf("<")) < 0 ? e : e.substring(0, n);
e = n < 0 ? "" : e.substring(n), t.chars && t.chars(d)
}
if (e === a) throw "Parse Error: " + e;
a = e
}
function u(e, n, i, r) {
if (V[n])
for (; o.last() && R[o.last()];) l(0, o.last());
if (U[n] && o.last() === n && l(0, n), (r = L[n] || !!r) || o.push(n), t.start) {
var a = [];
i.replace(N, function(e, t) {
var n = arguments[2] ? arguments[2] : arguments[3] ? arguments[3] : arguments[4] ? arguments[4] : J[t] ? t : "";
a.push({
name: t,
value: n,
escaped: n.replace(/(^|[^\\])"/g, '$1\\"')
})
}), t.start && t.start(n, a, r)
}
}
function l(e, n) {
if (n)
for (i = o.length - 1; i >= 0 && o[i] !== n; i--);
else var i = 0;
if (i >= 0) {
for (var r = o.length - 1; r >= i; r--) t.end && t.end(o[r]);
o.length = i
}
}
l()
}(e, {
start: function(e, i, o) {
if (z[e]) r = z[e];
else {
for (var a = t.createElement(e), s = 0; s < i.length; s++) a.setAttribute(i[s].name, i[s].value);
W[e] && "boolean" != typeof _one[W[e]] ? z[W[e]].appendChild(a) : r && r.appendChild && (window.addEventListener || "NOSCRIPT" !== r.tagName) && r.appendChild(a), o || (n.push(a), r = a)
}
},
end: function(e) {
n.length -= 1, r = n.length > 0 ? n[n.length - 1] : z.body
},
chars: function(e) {
if (window.addEventListener) {
var n = t.createTextNode(e);
r.appendChild(n)
} else r.text = e
},
comment: function(e) {}
})
}, window.BKTAG.util = {
addEvent: h,
getKwds: p,
getMeta: m,
isDebug: w,
isMobile: function() {
return ["Mobile", "Tablet", "Handheld", "Android", "iPhone", "Kindle", "Silk", "Nokia", "Symbian", "BlackBerry"].some(function(e) {
return -1 !== navigator.userAgent.indexOf(e)
})
},
normalizeEmail: v,
normalizePhone: g,
scriptWithOnload: function(e, t) {
var n = !1,
i = document.createElement("script");
i.onload = function() {
n || (n = !0, "function" == typeof t && t())
};
var r = i;
return r.onreadystatechange = function() {
var e = r.readyState;
("loaded" === e || "complete" === e) && !n && (n = !0, "function" == typeof t && t())
}, i.src = e, i
},
trim: function(e) {
return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "")
}
}, "function" == typeof window.bk_async && window.setTimeout(function() {
window.bk_async();
window.bk_async = function(){}; // CUSTOM MODIFIED CODE : Remove function to stop it firing again
}, 0)
// CUSTOM MODIFIED CODE : START
, "object" == typeof window.bk_async_queue && window.setTimeout(function() {
for (var i = 0; i < bk_async_queue.length; i++) {
if(typeof bk_async_queue[i] === "function"){
bk_async_queue[i]()
bk_async_queue.shift()
} else {
console.debug("Bktag : Error : item in 'bk_async_queue' array is not a function")
}
}
}, 0)
// CUSTOM MODIFIED CODE : END
},
5: function(e, t, n) {
"use strict";
var i = Object.prototype.hasOwnProperty,
r = Object.prototype.propertyIsEnumerable;
e.exports = function() {
try {
if (!Object.assign) return !1;
var e = new String("abc");
if (e[5] = "de", "5" === Object.getOwnPropertyNames(e)[0]) return !1;
for (var t = {}, n = 0; n < 10; n++) t["_" + String.fromCharCode(n)] = n;
if ("0123456789" !== Object.getOwnPropertyNames(t).map(function(e) {
return t[e]
}).join("")) return !1;
var i = {};
return "abcdefghijklmnopqrst".split("").forEach(function(e) {
i[e] = e
}), "abcdefghijklmnopqrst" === Object.keys(Object.assign({}, i)).join("")
} catch (e) {
return !1
}
}() ? Object.assign : function(e, t) {
for (var n, o, a = function(e) {
if (null == e) throw new TypeError("Object.assign cannot be called with null or undefined");
return Object(e)
}(e), s = 1; s < arguments.length; s++) {
for (var c in n = Object(arguments[s])) i.call(n, c) && (a[c] = n[c]);
if (Object.getOwnPropertySymbols) {
o = Object.getOwnPropertySymbols(n);
for (var d = 0; d < o.length; d++) r.call(n, o[d]) && (a[o[d]] = n[o[d]])
}
}
return a
}
},
6: function(e, t, n) {
var i;
e.exports = (i = i || function(e, t) {
var n = Object.create || function() {
function e() {}
return function(t) {
var n;
return e.prototype = t, n = new e, e.prototype = null, n
}
}(),
i = {},
r = i.lib = {},
o = r.Base = {
extend: function(e) {
var t = n(this);
return e && t.mixIn(e), t.hasOwnProperty("init") && this.init !== t.init || (t.init = function() {
t.$super.init.apply(this, arguments)
}), t.init.prototype = t, t.$super = this, t
},
create: function() {
var e = this.extend();
return e.init.apply(e, arguments), e
},
init: function() {},
mixIn: function(e) {
for (var t in e) e.hasOwnProperty(t) && (this[t] = e[t]);
e.hasOwnProperty("toString") && (this.toString = e.toString)
},
clone: function() {
return this.init.prototype.extend(this)
}
},
a = r.WordArray = o.extend({
init: function(e, t) {
e = this.words = e || [], this.sigBytes = null != t ? t : 4 * e.length
},
toString: function(e) {
return (e || c).stringify(this)
},
concat: function(e) {
var t = this.words,
n = e.words,
i = this.sigBytes,
r = e.sigBytes;
if (this.clamp(), i % 4)
for (var o = 0; o < r; o++) {
var a = n[o >>> 2] >>> 24 - o % 4 * 8 & 255;
t[i + o >>> 2] |= a << 24 - (i + o) % 4 * 8
} else
for (var o = 0; o < r; o += 4) t[i + o >>> 2] = n[o >>> 2];
return this.sigBytes += r, this
},
clamp: function() {
var t = this.words,
n = this.sigBytes;
t[n >>> 2] &= 4294967295 << 32 - n % 4 * 8, t.length = e.ceil(n / 4)
},
clone: function() {
var e = o.clone.call(this);
return e.words = this.words.slice(0), e
},
random: function(t) {
for (var n, i = [], r = function(t) {
var t = t,
n = 987654321,
i = 4294967295;
return function() {
var r = ((n = 36969 * (65535 & n) + (n >> 16) & i) << 16) + (t = 18e3 * (65535 & t) + (t >> 16) & i) & i;
return r /= 4294967296, (r += .5) * (e.random() > .5 ? 1 : -1)
}
}, o = 0; o < t; o += 4) {
var s = r(4294967296 * (n || e.random()));
n = 987654071 * s(), i.push(4294967296 * s() | 0)
}
return new a.init(i, t)
}
}),
s = i.enc = {},
c = s.Hex = {
stringify: function(e) {
for (var t = e.words, n = e.sigBytes, i = [], r = 0; r < n; r++) {
var o = t[r >>> 2] >>> 24 - r % 4 * 8 & 255;
i.push((o >>> 4).toString(16)), i.push((15 & o).toString(16))
}
return i.join("")
},
parse: function(e) {
for (var t = e.length, n = [], i = 0; i < t; i += 2) n[i >>> 3] |= parseInt(e.substr(i, 2), 16) << 24 - i % 8 * 4;
return new a.init(n, t / 2)
}
},
d = s.Latin1 = {
stringify: function(e) {
for (var t = e.words, n = e.sigBytes, i = [], r = 0; r < n; r++) {
var o = t[r >>> 2] >>> 24 - r % 4 * 8 & 255;
i.push(String.fromCharCode(o))
}
return i.join("")
},
parse: function(e) {
for (var t = e.length, n = [], i = 0; i < t; i++) n[i >>> 2] |= (255 & e.charCodeAt(i)) << 24 - i % 4 * 8;
return new a.init(n, t)
}
},
u = s.Utf8 = {
stringify: function(e) {
try {
return decodeURIComponent(escape(d.stringify(e)))
} catch (e) {
throw new Error("Malformed UTF-8 data")
}
},
parse: function(e) {
return d.parse(unescape(encodeURIComponent(e)))
}
},
l = r.BufferedBlockAlgorithm = o.extend({
reset: function() {
this._data = new a.init, this._nDataBytes = 0
},
_append: function(e) {
"string" == typeof e && (e = u.parse(e)), this._data.concat(e), this._nDataBytes += e.sigBytes
},
_process: function(t) {
var n = this._data,
i = n.words,
r = n.sigBytes,
o = this.blockSize,
s = 4 * o,
c = r / s,
d = (c = t ? e.ceil(c) : e.max((0 | c) - this._minBufferSize, 0)) * o,
u = e.min(4 * d, r);
if (d) {
for (var l = 0; l < d; l += o) this._doProcessBlock(i, l);
var f = i.splice(0, d);
n.sigBytes -= u
}
return new a.init(f, u)
},
clone: function() {
var e = o.clone.call(this);
return e._data = this._data.clone(), e
},
_minBufferSize: 0
}),
f = (r.Hasher = l.extend({
cfg: o.extend(),
init: function(e) {
this.cfg = this.cfg.extend(e), this.reset()
},
reset: function() {
l.reset.call(this), this._doReset()
},
update: function(e) {
return this._append(e), this._process(), this
},
finalize: function(e) {
e && this._append(e);
var t = this._doFinalize();
return t
},
blockSize: 16,
_createHelper: function(e) {
return function(t, n) {
return new e.init(n).finalize(t)
}
},
_createHmacHelper: function(e) {
return function(t, n) {
return new f.HMAC.init(e, n).finalize(t)
}
}
}), i.algo = {});
return i
}(Math), i)
},
7: function(e, t, n) {
var i;
e.exports = (i = n(6), function(e) {
var t = i,
n = t.lib,
r = n.WordArray,
o = n.Hasher,
a = t.algo,
s = [],
c = [];
! function() {
function t(t) {
for (var n = e.sqrt(t), i = 2; i <= n; i++)
if (!(t % i)) return !1;
return !0
}
function n(e) {
return 4294967296 * (e - (0 | e)) | 0
}
for (var i = 2, r = 0; r < 64;) t(i) && (r < 8 && (s[r] = n(e.pow(i, .5))), c[r] = n(e.pow(i, 1 / 3)), r++), i++
}();
var d = [],
u = a.SHA256 = o.extend({
_doReset: function() {
this._hash = new r.init(s.slice(0))
},
_doProcessBlock: function(e, t) {
for (var n = this._hash.words, i = n[0], r = n[1], o = n[2], a = n[3], s = n[4], u = n[5], l = n[6], f = n[7], p = 0; p < 64; p++) {
if (p < 16) d[p] = 0 | e[t + p];
else {
var m = d[p - 15],
w = (m << 25 | m >>> 7) ^ (m << 14 | m >>> 18) ^ m >>> 3,
h = d[p - 2],
v = (h << 15 | h >>> 17) ^ (h << 13 | h >>> 19) ^ h >>> 10;
d[p] = w + d[p - 7] + v + d[p - 16]
}
var g = i & r ^ i & o ^ r & o,
b = (i << 30 | i >>> 2) ^ (i << 19 | i >>> 13) ^ (i << 10 | i >>> 22),
y = f + ((s << 26 | s >>> 6) ^ (s << 21 | s >>> 11) ^ (s << 7 | s >>> 25)) + (s & u ^ ~s & l) + c[p] + d[p];
f = l, l = u, u = s, s = a + y | 0, a = o, o = r, r = i, i = y + (b + g) | 0
}
n[0] = n[0] + i | 0, n[1] = n[1] + r | 0, n[2] = n[2] + o | 0, n[3] = n[3] + a | 0, n[4] = n[4] + s | 0, n[5] = n[5] + u | 0, n[6] = n[6] + l | 0, n[7] = n[7] + f | 0
},
_doFinalize: function() {
var t = this._data,
n = t.words,
i = 8 * this._nDataBytes,
r = 8 * t.sigBytes;
return n[r >>> 5] |= 128 << 24 - r % 32, n[14 + (r + 64 >>> 9 << 4)] = e.floor(i / 4294967296), n[15 + (r + 64 >>> 9 << 4)] = i, t.sigBytes = 4 * n.length, this._process(), this._hash
},
clone: function() {
var e = o.clone.call(this);
return e._hash = this._hash.clone(), e
}
});
t.SHA256 = o._createHelper(u), t.HmacSHA256 = o._createHmacHelper(u)
}(Math), i.SHA256)
},
8: function(e, t, n) {
var i;
e.exports = (i = n(6), function(e) {
var t = i,
n = t.lib,
r = n.WordArray,
o = n.Hasher,
a = t.algo,
s = [];
! function() {
for (var t = 0; t < 64; t++) s[t] = 4294967296 * e.abs(e.sin(t + 1)) | 0
}();
var c = a.MD5 = o.extend({
_doReset: function() {
this._hash = new r.init([1732584193, 4023233417, 2562383102, 271733878])
},
_doProcessBlock: function(e, t) {
for (var n = 0; n < 16; n++) {
var i = t + n,
r = e[i];
e[i] = 16711935 & (r << 8 | r >>> 24) | 4278255360 & (r << 24 | r >>> 8)
}
var o = this._hash.words,
a = e[t + 0],
c = e[t + 1],
p = e[t + 2],
m = e[t + 3],
w = e[t + 4],
h = e[t + 5],
v = e[t + 6],
g = e[t + 7],
b = e[t + 8],
y = e[t + 9],
_ = e[t + 10],
k = e[t + 11],
x = e[t + 12],
T = e[t + 13],
B = e[t + 14],
C = e[t + 15],
O = o[0],
S = o[1],
A = o[2],
E = o[3];
O = d(O, S, A, E, a, 7, s[0]), E = d(E, O, S, A, c, 12, s[1]), A = d(A, E, O, S, p, 17, s[2]), S = d(S, A, E, O, m, 22, s[3]), O = d(O, S, A, E, w, 7, s[4]), E = d(E, O, S, A, h, 12, s[5]), A = d(A, E, O, S, v, 17, s[6]), S = d(S, A, E, O, g, 22, s[7]), O = d(O, S, A, E, b, 7, s[8]), E = d(E, O, S, A, y, 12, s[9]), A = d(A, E, O, S, _, 17, s[10]), S = d(S, A, E, O, k, 22, s[11]), O = d(O, S, A, E, x, 7, s[12]), E = d(E, O, S, A, T, 12, s[13]), A = d(A, E, O, S, B, 17, s[14]), O = u(O, S = d(S, A, E, O, C, 22, s[15]), A, E, c, 5, s[16]), E = u(E, O, S, A, v, 9, s[17]), A = u(A, E, O, S, k, 14, s[18]), S = u(S, A, E, O, a, 20, s[19]), O = u(O, S, A, E, h, 5, s[20]), E = u(E, O, S, A, _, 9, s[21]), A = u(A, E, O, S, C, 14, s[22]), S = u(S, A, E, O, w, 20, s[23]), O = u(O, S, A, E, y, 5, s[24]), E = u(E, O, S, A, B, 9, s[25]), A = u(A, E, O, S, m, 14, s[26]), S = u(S, A, E, O, b, 20, s[27]), O = u(O, S, A, E, T, 5, s[28]), E = u(E, O, S, A, p, 9, s[29]), A = u(A, E, O, S, g, 14, s[30]), O = l(O, S = u(S, A, E, O, x, 20, s[31]), A, E, h, 4, s[32]), E = l(E, O, S, A, b, 11, s[33]), A = l(A, E, O, S, k, 16, s[34]), S = l(S, A, E, O, B, 23, s[35]), O = l(O, S, A, E, c, 4, s[36]), E = l(E, O, S, A, w, 11, s[37]), A = l(A, E, O, S, g, 16, s[38]), S = l(S, A, E, O, _, 23, s[39]), O = l(O, S, A, E, T, 4, s[40]), E = l(E, O, S, A, a, 11, s[41]), A = l(A, E, O, S, m, 16, s[42]), S = l(S, A, E, O, v, 23, s[43]), O = l(O, S, A, E, y, 4, s[44]), E = l(E, O, S, A, x, 11, s[45]), A = l(A, E, O, S, C, 16, s[46]), O = f(O, S = l(S, A, E, O, p, 23, s[47]), A, E, a, 6, s[48]), E = f(E, O, S, A, g, 10, s[49]), A = f(A, E, O, S, B, 15, s[50]), S = f(S, A, E, O, h, 21, s[51]), O = f(O, S, A, E, x, 6, s[52]), E = f(E, O, S, A, m, 10, s[53]), A = f(A, E, O, S, _, 15, s[54]), S = f(S, A, E, O, c, 21, s[55]), O = f(O, S, A, E, b, 6, s[56]), E = f(E, O, S, A, C, 10, s[57]), A = f(A, E, O, S, v, 15, s[58]), S = f(S, A, E, O, T, 21, s[59]), O = f(O, S, A, E, w, 6, s[60]), E = f(E, O, S, A, k, 10, s[61]), A = f(A, E, O, S, p, 15, s[62]), S = f(S, A, E, O, y, 21, s[63]), o[0] = o[0] + O | 0, o[1] = o[1] + S | 0, o[2] = o[2] + A | 0, o[3] = o[3] + E | 0
},
_doFinalize: function() {
var t = this._data,
n = t.words,
i = 8 * this._nDataBytes,
r = 8 * t.sigBytes;
n[r >>> 5] |= 128 << 24 - r % 32;
var o = e.floor(i / 4294967296),
a = i;
n[15 + (r + 64 >>> 9 << 4)] = 16711935 & (o << 8 | o >>> 24) | 4278255360 & (o << 24 | o >>> 8), n[14 + (r + 64 >>> 9 << 4)] = 16711935 & (a << 8 | a >>> 24) | 4278255360 & (a << 24 | a >>> 8), t.sigBytes = 4 * (n.length + 1), this._process();
for (var s = this._hash, c = s.words, d = 0; d < 4; d++) {
var u = c[d];
c[d] = 16711935 & (u << 8 | u >>> 24) | 4278255360 & (u << 24 | u >>> 8)
}
return s
},
clone: function() {
var e = o.clone.call(this);
return e._hash = this._hash.clone(), e
}
});
function d(e, t, n, i, r, o, a) {
var s = e + (t & n | ~t & i) + r + a;
return (s << o | s >>> 32 - o) + t
}
function u(e, t, n, i, r, o, a) {
var s = e + (t & i | n & ~i) + r + a;
return (s << o | s >>> 32 - o) + t
}
function l(e, t, n, i, r, o, a) {
var s = e + (t ^ n ^ i) + r + a;
return (s << o | s >>> 32 - o) + t
}
function f(e, t, n, i, r, o, a) {
var s = e + (n ^ (t | ~i)) + r + a;
return (s << o | s >>> 32 - o) + t
}
t.MD5 = o._createHelper(c), t.HmacMD5 = o._createHmacHelper(c)
}(Math), i.MD5)
}
});
<!-- Begin BlueKai Tag -->
<!--
- Search "Custom Code" for custom lines of code
-->
<script type="text/javascript">
// ALLOW MULTIPLE CALLS/SINGLE PAGE APPS
bk_allow_multiple_calls = true;
bk_use_multiple_iframes = true;
window.bk_async_queue = window.bk_async_queue || []; // Custom Code
window.bk_async_queue.push(function() { // Custom Code
// <optional> PHINTS : Declare variables about this page (or user)
bk_addPageCtx('page_type', 'article'); // example phint (change to your own useful variabes)
bk_addPageCtx('section', 'news'); // example phint (change to your own useful variabes)
bk_addPageCtx('another_example_var', 'another value'); // example phint (change to your own useful variabes)
/*
<optional> IDs : Depending on your deployment, IDs may be useful for joining offline data to a visitor's profile to add additional targeting capabilities. If you have these for users, please declare them
*/
// <optional> Customer ID
bk_addPageCtx('customer_id', 'YOUR CUSTOMER ID');
// <optional> Email Address (this will be MD5 and SHA-256 hashed)
bk_addEmailHash('ENTER EMAIL ADDRESS HERE');
// <optional> Phone Number (this will be MD5 and SHA-256 hashed)
bk_addPhoneHash('ENTER PHONE NUMBER HERE');
// Send Data
BKTAG.doTag(12345, 4); // change "ENTER CONTAINER ID HERE" to the container ID/Site ID you want to use
});
(function() {
var scripts = document.getElementsByTagName('script')[0];
var s = document.createElement('script');
s.async = true;
s.src = "https://roshansfilebucket.s3-eu-west-1.amazonaws.com/Oracle/DMP/bkcoretag/bk-coretag_custom.js"; // Custom Code
scripts.parentNode.insertBefore(s, scripts);
}
}());
</script>
<!-- End BlueKai Tag -->