Created
February 2, 2017 14:13
-
-
Save dashaluna/ebed6ae7cadd8083457811e1655e7eff to your computer and use it in GitHub Desktop.
Ooyala iframe markup with ads for FB IA
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FB IA markup: | |
<p>Official ooyala plugin shortcode:</p> | |
<figure class="op-interactive"> | |
<iframe | |
src="https://thesuncouk-develop.go-vip.co/ooyala-iframe/33447?code=t4OWo4NTE6Ye7cqQPGJ7ZPXNTA0ULOrj&player_id=YmRmN2I0ZDMwNDI5NTFlZGI4NDM1OWM4&width=1920&height=1080&caption=test_ooyala_upload_02.mp4&auto=true" | |
class="no-margin" width="480" height="320"></iframe> | |
</figure> | |
<p>Our custom generated iframe & player:</p> | |
<figure class="op-interactive"> | |
<iframe | |
src="https://thesuncouk-develop.go-vip.co/ooyala-iframe/33447?code=t4OWo4NTE6Ye7cqQPGJ7ZPXNTA0ULOrj&player_id=YmRmN2I0ZDMwNDI5NTFlZGI4NDM1OWM4&width=1920&height=1080&caption=test_ooyala_upload_02.mp4&auto=true" | |
class="no-margin" width="480" height="320"></iframe> | |
</figure> | |
Iframe markup: | |
NB: NREUM is inserted by WP VIP, but shouldn't affect things. I left it all in for full picture. | |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<script type="text/javascript">window.NREUM || (NREUM = {}), __nr_require = function (e, t, n) { | |
function r(n) { | |
if (!t[n]) { | |
var o = t[n] = {exports: {}}; | |
e[n][0].call(o.exports, function (t) { | |
var o = e[n][1][t]; | |
return r(o || t) | |
}, o, o.exports) | |
} | |
return t[n].exports | |
} | |
if ("function" == typeof __nr_require)return __nr_require; | |
for (var o = 0; o < n.length; o++)r(n[o]); | |
return r | |
}({ | |
1: [function (e, t, n) { | |
function r() { | |
} | |
function o(e, t, n) { | |
return function () { | |
return i(e, [(new Date).getTime()].concat(u(arguments)), t ? null : this, n), t ? void 0 : this | |
} | |
} | |
var i = e("handle"), a = e(2), u = e(3), c = e("ee").get("tracer"), f = NREUM; | |
"undefined" == typeof window.newrelic && (newrelic = f); | |
var s = ["setPageViewName", "setCustomAttribute", "setErrorHandler", "finished", "addToTrace", "inlineHit", "addRelease"], l = "api-", p = l + "ixn-"; | |
a(s, function (e, t) { | |
f[t] = o(l + t, !0, "api") | |
}), f.addPageAction = o(l + "addPageAction", !0), f.setCurrentRouteName = o(l + "routeName", !0), t.exports = newrelic, f.interaction = function () { | |
return (new r).get() | |
}; | |
var d = r.prototype = { | |
createTracer: function (e, t) { | |
var n = {}, r = this, o = "function" == typeof t; | |
return i(p + "tracer", [Date.now(), e, n], r), function () { | |
if (c.emit((o ? "" : "no-") + "fn-start", [Date.now(), r, o], n), o)try { | |
return t.apply(this, arguments) | |
} finally { | |
c.emit("fn-end", [Date.now()], n) | |
} | |
} | |
} | |
}; | |
a("setName,setAttribute,save,ignore,onEnd,getContext,end,get".split(","), function (e, t) { | |
d[t] = o(p + t) | |
}), newrelic.noticeError = function (e) { | |
"string" == typeof e && (e = new Error(e)), i("err", [e, (new Date).getTime()]) | |
} | |
}, {}], 2: [function (e, t, n) { | |
function r(e, t) { | |
var n = [], r = "", i = 0; | |
for (r in e)o.call(e, r) && (n[i] = t(r, e[r]), i += 1); | |
return n | |
} | |
var o = Object.prototype.hasOwnProperty; | |
t.exports = r | |
}, {}], 3: [function (e, t, n) { | |
function r(e, t, n) { | |
t || (t = 0), "undefined" == typeof n && (n = e ? e.length : 0); | |
for (var r = -1, o = n - t || 0, i = Array(o < 0 ? 0 : o); ++r < o;)i[r] = e[t + r]; | |
return i | |
} | |
t.exports = r | |
}, {}], ee: [function (e, t, n) { | |
function r() { | |
} | |
function o(e) { | |
function t(e) { | |
return e && e instanceof r ? e : e ? c(e, u, i) : i() | |
} | |
function n(n, r, o) { | |
if (!p.aborted) { | |
e && e(n, r, o); | |
for (var i = t(o), a = v(n), u = a.length, c = 0; c < u; c++)a[c].apply(i, r); | |
var f = s[w[n]]; | |
return f && f.push([y, n, r, i]), i | |
} | |
} | |
function d(e, t) { | |
b[e] = v(e).concat(t) | |
} | |
function v(e) { | |
return b[e] || [] | |
} | |
function g(e) { | |
return l[e] = l[e] || o(n) | |
} | |
function m(e, t) { | |
f(e, function (e, n) { | |
t = t || "feature", w[n] = t, t in s || (s[t] = []) | |
}) | |
} | |
var b = {}, w = {}, y = { | |
on: d, | |
emit: n, | |
get: g, | |
listeners: v, | |
context: t, | |
buffer: m, | |
abort: a, | |
aborted: !1 | |
}; | |
return y | |
} | |
function i() { | |
return new r | |
} | |
function a() { | |
(s.api || s.feature) && (p.aborted = !0, s = p.backlog = {}) | |
} | |
var u = "nr@context", c = e("gos"), f = e(2), s = {}, l = {}, p = t.exports = o(); | |
p.backlog = s | |
}, {}], gos: [function (e, t, n) { | |
function r(e, t, n) { | |
if (o.call(e, t))return e[t]; | |
var r = n(); | |
if (Object.defineProperty && Object.keys)try { | |
return Object.defineProperty(e, t, {value: r, writable: !0, enumerable: !1}), r | |
} catch (i) { | |
} | |
return e[t] = r, r | |
} | |
var o = Object.prototype.hasOwnProperty; | |
t.exports = r | |
}, {}], handle: [function (e, t, n) { | |
function r(e, t, n, r) { | |
o.buffer([e], r), o.emit(e, t, n) | |
} | |
var o = e("ee").get("handle"); | |
t.exports = r, r.ee = o | |
}, {}], id: [function (e, t, n) { | |
function r(e) { | |
var t = typeof e; | |
return !e || "object" !== t && "function" !== t ? -1 : e === window ? 0 : a(e, i, function () { | |
return o++ | |
}) | |
} | |
var o = 1, i = "nr@id", a = e("gos"); | |
t.exports = r | |
}, {}], loader: [function (e, t, n) { | |
function r() { | |
if (!h++) { | |
var e = y.info = NREUM.info, t = l.getElementsByTagName("script")[0]; | |
if (setTimeout(f.abort, 3e4), !(e && e.licenseKey && e.applicationID && t))return f.abort(); | |
c(b, function (t, n) { | |
e[t] || (e[t] = n) | |
}), u("mark", ["onload", a()], null, "api"); | |
var n = l.createElement("script"); | |
n.src = "https://" + e.agent, t.parentNode.insertBefore(n, t) | |
} | |
} | |
function o() { | |
"complete" === l.readyState && i() | |
} | |
function i() { | |
u("mark", ["domContent", a()], null, "api") | |
} | |
function a() { | |
return (new Date).getTime() | |
} | |
var u = e("handle"), c = e(2), f = e("ee"), s = window, l = s.document, p = "addEventListener", d = "attachEvent", v = s.XMLHttpRequest, g = v && v.prototype; | |
NREUM.o = { | |
ST: setTimeout, | |
CT: clearTimeout, | |
XHR: v, | |
REQ: s.Request, | |
EV: s.Event, | |
PR: s.Promise, | |
MO: s.MutationObserver | |
}, e(1); | |
var m = "" + location, b = { | |
beacon: "bam.nr-data.net", | |
errorBeacon: "bam.nr-data.net", | |
agent: "js-agent.newrelic.com/nr-1016.min.js" | |
}, w = v && g && g[p] && !/CriOS/.test(navigator.userAgent), y = t.exports = { | |
offset: a(), | |
origin: m, | |
features: {}, | |
xhrWrappable: w | |
}; | |
l[p] ? (l[p]("DOMContentLoaded", i, !1), s[p]("load", r, !1)) : (l[d]("onreadystatechange", o), s[d]("onload", r)), u("mark", ["firstbyte", a()], null, "api"); | |
var h = 0 | |
}, {}] | |
}, {}, ["loader"]);</script> | |
<link rel="stylesheet" href="https://player.ooyala.com/static/v4/stable/4.10.4/skin-plugin/html5-skin.min.css"/> | |
<script language="JavaScript" src="https://player.ooyala.com/static/v4/stable/4.10.4/core.min.js"></script> | |
<script language="JavaScript" | |
src="https://player.ooyala.com/static/v4/stable/4.10.4/video-plugin/main_html5.min.js"></script> | |
<script language="JavaScript" | |
src="https://player.ooyala.com/static/v4/stable/4.10.4/video-plugin/bit_wrapper.min.js"></script> | |
<script language="JavaScript" | |
src="https://player.ooyala.com/static/v4/stable/4.10.4/skin-plugin/html5-skin.min.js"></script> | |
<script language="JavaScript" | |
src="https://player.ooyala.com/static/v4/stable/4.10.4/ad-plugin/google_ima.min.js"></script> | |
</head> | |
<body> | |
<!-- Player V4 Content--> | |
<div id="container"></div> | |
<script> | |
var playerParam = { | |
"pcode": "FveWs6Uu0lPuwExpNTAQ-_NjeV8e", | |
"playerBrandingId": "YmRmN2I0ZDMwNDI5NTFlZGI4NDM1OWM4", | |
"skin": {"config": "https:\/\/player.ooyala.com\/static\/v4\/stable\/latest\/skin-plugin\/skin.json"}, | |
"google-ima-ads-manager": { | |
"all_ads": [{ | |
"position_type": "r", | |
"tag_url": "https:\/\/pubads.g.doubleclick.net\/gampad\/ads?env=vp&gdfp_req=1&impl=s&output=xml_vast3&iu=25436805\/d.thesun\/Living&sz=640x480&unviewed_position_start=1&url=https%3A%2F%2Fthesuncouk-develop.go-vip.co%2Fliving%2F33447%2Ftesting-fbia-ooyala-preroll%2F&description_url=https%3A%2F%2Fthesuncouk-develop.go-vip.co%2Fliving%2F33447%2Ftesting-fbia-ooyala-preroll%2F&vpos=preroll&vid=t4OWo4NTE6Ye7cqQPGJ7ZPXNTA0ULOrj&cmsid=4974&correlator=1486044664" | |
}], | |
"additionalAdTagParameters": { | |
"section": "Living", | |
"topic": "", | |
"kw": "testing,fbia,ooyala,preroll,,deardeidre,living", | |
"aid": 33447, | |
"content_url": "https:\/\/thesuncouk-develop.go-vip.co\/living\/33447\/testing-fbia-ooyala-preroll\/", | |
"amp": "true", | |
"cont_type": "art", | |
"pos": "videoplayer" | |
} | |
} | |
}; | |
// Surround everything with OO.ready to make sure the script has loaded and initialized. | |
OO.ready(function () { | |
window.pp = OO.Player.create('container', "t4OWo4NTE6Ye7cqQPGJ7ZPXNTA0ULOrj", playerParam); | |
}); | |
</script> | |
<script type="text/javascript">window.NREUM || (NREUM = {}); | |
NREUM.info = { | |
"beacon": "bam.nr-data.net", | |
"licenseKey": "12f4312a27", | |
"applicationID": "18119689", | |
"transactionName": "YFxWYEpUVhJQAUMIXFkWdVdMXFcPHgtRE1JaXBlbV0xZDVA=", | |
"queueTime": 0, | |
"applicationTime": 45, | |
"atts": "TBtBFgJORU0TAxVbSEpE", | |
"errorBeacon": "bam.nr-data.net", | |
"agent": "" | |
}</script> | |
</body> | |
</html> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment