parent
6ff9a51058
commit
c782f73f30
1 changed files with 45 additions and 16 deletions
|
@ -558,18 +558,49 @@ export default React.memo<Props>(function VideoJs(props: Props) {
|
||||||
// 612fb75a42715a07645a614c
|
// 612fb75a42715a07645a614c
|
||||||
|
|
||||||
// Modified to work with IMA
|
// Modified to work with IMA
|
||||||
const macroUrl =
|
// const macroUrl =
|
||||||
`https://vast.aniview.com/api/adserver61/vast/` +
|
// `https://vast.aniview.com/api/adserver61/vast/` +
|
||||||
`?AV_PUBLISHERID=60afcbc58cfdb065440d2426` +
|
// `?AV_PUBLISHERID=60afcbc58cfdb065440d2426` +
|
||||||
`&AV_CHANNELID=60b354389c7adb506d0bd9a4` +
|
// `&AV_CHANNELID=60b354389c7adb506d0bd9a4` +
|
||||||
`&AV_URL=[URL]` +
|
// `&AV_URL=[URL]` +
|
||||||
`&cb=[CACHEBUSTING]` +
|
// `&cb=[CACHEBUSTING]` +
|
||||||
`&AV_WIDTH=[WIDTH]` +
|
// `&AV_WIDTH=[WIDTH]` +
|
||||||
`&AV_HEIGHT=[HEIGHT]` +
|
// `&AV_HEIGHT=[HEIGHT]` +
|
||||||
// `&AV_SCHAIN=[SCHAIN_MACRO]` +
|
// // `&AV_SCHAIN=[SCHAIN_MACRO]` +
|
||||||
// `&AV_CCPA=[CCPA_MACRO]` +
|
// // `&AV_CCPA=[CCPA_MACRO]` +
|
||||||
// `&AV_GDPR=[GDPR_MACRO]` +
|
// // `&AV_GDPR=[GDPR_MACRO]` +
|
||||||
// `&AV_CONSENT=[CONSENT_MACRO]` +
|
// // `&AV_CONSENT=[CONSENT_MACRO]` +
|
||||||
|
// `&skip=true` +
|
||||||
|
// `&skiptimer=5` +
|
||||||
|
// `&logo=true` +
|
||||||
|
// `&usevslot=true` +
|
||||||
|
// `&vastretry=2` +
|
||||||
|
// `&hidecontrols=false`;
|
||||||
|
|
||||||
|
const timestamp = new Date().toISOString();
|
||||||
|
|
||||||
|
const videoElement = document.getElementsByClassName('vjs-tech')[0];
|
||||||
|
|
||||||
|
const height = videoElement.offsetHeight;
|
||||||
|
const width = videoElement.offsetWidth;
|
||||||
|
|
||||||
|
// live channel
|
||||||
|
// 60b354389c7adb506d0bd9a4
|
||||||
|
|
||||||
|
// ford ad
|
||||||
|
// 612fb75a42715a07645a614c
|
||||||
|
|
||||||
|
const macroUrl1 = 'https://gov.aniview.com/api/adserver/vast3/' +
|
||||||
|
'?AV_PUBLISHERID=60afcbc58cfdb065440d2426' +
|
||||||
|
'&AV_CHANNELID=60b354389c7adb506d0bd9a4' +
|
||||||
|
`&AV_URL=${encodeURIComponent(window.location.href)}` +
|
||||||
|
`&cb=${encodeURIComponent(timestamp)}` +
|
||||||
|
`&AV_WIDTH=${width}` +
|
||||||
|
`&AV_HEIGHT=${height}` +
|
||||||
|
// '&AV_SCHAIN=[SCHAIN_MACRO]' +
|
||||||
|
// '&AV_CCPA=[CCPA_MACRO]' +
|
||||||
|
// '&AV_GDPR=[GDPR_MACRO]' +
|
||||||
|
// '&AV_CONSENT=[CONSENT_MACRO]' +
|
||||||
`&skip=true` +
|
`&skip=true` +
|
||||||
`&skiptimer=5` +
|
`&skiptimer=5` +
|
||||||
`&logo=true` +
|
`&logo=true` +
|
||||||
|
@ -590,10 +621,8 @@ export default React.memo<Props>(function VideoJs(props: Props) {
|
||||||
if (shouldShowAnAd && browserIsChrome && !IS_MOBILE) {
|
if (shouldShowAnAd && browserIsChrome && !IS_MOBILE) {
|
||||||
// fire up ima integration via module
|
// fire up ima integration via module
|
||||||
player.ima({
|
player.ima({
|
||||||
adTagUrl: macroUrl,
|
adTagUrl: macroUrl1,
|
||||||
vpaidMode: 2, // 2 = INSECURE
|
vpaidMode: 2,
|
||||||
// // $FlowFixMe
|
|
||||||
// vpaidMode: google.ima.ImaSdkSettings.VpaidMode.INSECURE,
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue