Order Now AdSolution Sign Up | Login » Bits on the Run Sign Up | Login »

Forums

/

OVA and Flowplayer playlist events

13 replies [Last post]
Reply

I have a question about the interaction of OVA and the playlist events for Flowplayer. It looks like OVA suppresses the firing (or maybe the JS registration) of the onStart and onFinish events that are defined just on playlist items.

Interestingly, this doesn't occur for event handlers that are defined on the clip. Is this expected behavior?

Reply

Strange... I can't think of a reason why it would be doing this - but I'll investigate and come back to you with thoughts.

If it is doing something to block the events firing, I'll fix that... because it definitely shouldn't be...

Give me 24 hour to investigate ;)

Paul

Reply

Paul,

Any insight into this? I was able to code around the issue but it would be nice if I didn't have to.

Reply

Hi Murray,

So sorry, I forgot to give you an update on this.

I've been looking into it. You are certainly right, those playlist defined events are being lost - the problem is, I can't precisely work out why.

I'm still getting to the bottom of it. I suspect it is because I'm redeclaring the clip once OVA has completed ad scheduling and those events are being dropped.

Right now, I'm in the middle of a major change to support onDemand loading so it's difficult to resolve this quickly this week - what's your timing on this? Do you need an immediate resolution or is this something that I have a few days to check-in a fix on?

I think to fix it, I have to make a significant change to the clip scheduling element of OVA for Flowplayer and look to retain existing clips and insert them back into the new playlist (but that's been problematic in the past, hence why this type of problem may be coming up)....

Paul

Reply

I don't need it immediately. I was able to put the event on the main clip and then do testing inside of the function to determine if I actually wanted to do anything. My only concern with that was I'm not sure my test was correct. I ended up doing:

        onStart: function() {
          var clip = arguments[0];
          if ((clip.type == 'video') && (typeof clip.ovaAd === 'undefined')) {
             // do something
          }
        },

Is that the right test? Is there something better to do instead?

Reply

Hi, there are OVA specific callbacks that are generated when ads play. If you want to do something related to an OVA scheduled ad, then it's probably better to use those.

You don't declare them on clips etc. - you put them outside of the Flowplayer block.

The set of calls in OVA for Flowplayer 0.6.0 RC4 includes:

onAdSchedulingStarted()
onLinearAdScheduled(ad:Object)
onNonLinearAdScheduled(ad:Object)
onCompanionAdScheduled(divSpecification:Object, companionAd:Object, parentAd:Object)
onAdSchedulingComplete(ads:Array)

onTemplateLoadSuccess(template:String)
onTemplateLoadFailure(error:String)
onTemplateLoadTimeout(error:String)

onLinearAdStart(ad:Object)
onLinearAdStop(ad:Object)
onLinearAdPause(ad:Object)
onLinearAdResume(ad:Object)
onLinearAdFullscreen(ad:Object)
onLinearAdFullscreenExit(ad:Object)
onLinearAdMute(ad:Object)
onLinearAdUnmute(ad:Object)
onLinearAdReplay(ad:Object)
onLinearAdMidPointComplete(ad:Object)
onLinearAdFirstQuartileComplete(ad:Object)
onLinearAdThirdQuartileComplete(ad:Object)
onLinearAdFinish(ad:Object)

onAdSlotLoaded(adSlot:Object)
onAdSlotLoadError(message:String)
onAdSlotLoadTimeout(message:String)
onAdSlotLoadDeferred(message:String)

onVPAIDAdLoaded(ad:Object, runtimeState:Object)
onVPAIDAdImpression(ad:Object, runtimeState:Object)
onVPAIDAdStart(ad:Object, runtimeState:Object)
onVPAIDAdComplete(ad:Object, runtimeState:Object)
onVPAIDAdError(ad:Object, runtimeState:Object)
onVPAIDAdVideoStart(ad:Object, runtimeState:Object)
onVPAIDAdVideoFirstQuartile(ad:Object, runtimeState:Object)
onVPAIDAdVideoMidpoint(ad:Object, runtimeState:Object)
onVPAIDAdVideoThirdQuartile(ad:Object, runtimeState:Object)
onVPAIDAdVideoComplete(ad:Object, runtimeState:Object)
onVPAIDAdClickThru(ad:Object, runtimeState:Object)
onVPAIDAdUserAcceptInvitation(ad:Object, runtimeState:Object)
onVPAIDAdUserMinimize(ad:Object, runtimeState:Object)
onVPAIDAdUserClose(ad:Object, runtimeState:Object)
onVPAIDAdPaused(ad:Object, runtimeState:Object)
onVPAIDAdPlaying(ad:Object, runtimeState:Object)
onVPAIDAdExpandedChange(ad:Object, runtimeState:Object)
onVPAIDAdLinearChange(ad:Object, runtimeState:Object)
onVPAIDAdRemainingTimeChange(ad:Object, runtimeState:Object)
onVPAIDAdLog(ad:Object, event:Object)

See this RC4 release note - section 17 for more details.

http://developer.longtailvideo.com/ova/wiki/OvaReleaseNote-0.5.0-RC4

Here's a set of examples that demonstrate these calls working in practice:

http://static.openvideoads.org/qa/latest/ova.flowplayer/examples/javascript/index.html

You need to look at the Javascript console (Chrome or Firebug etc.) to see the output...

Does that help?

Paul

Reply

I actually wanted to do something (capture analytics information) on the non-OVA ads videos. Registering the onStart and onFinish Flowplayer events on the main clip causes those to fire for ads too (since they become playlist clips). So my test was to exclude the ads before executing my code.

It seems to be working, my biggest concerns were that the test might not be correct in all cases and might not be stable over time.

Reply

Ok, gotcha.

It should be ok..

That "ovaAd" variable is a stable setting that has and always will be set.. so you can rely on it..

Anything that OVA schedules as an ad has that set.

;)

Paul

Reply

Hi,

I've got the same issue but with an (flash / as3) plugin ... as soon as i load the OVA-Plugin the "onBegin" Event (in flash - not js!) gets messed up and stops working/triggering the onBegin event.

Without the OVA Plugin "player.playlist.getClip(1).onBegin(onBegin);" as event listener works like a charme - with ova loaded it stops working.

Reply

Hi,

Well that's primarily because OVA completely changes the playlist. The original playlist is replaced with a new playlist of clips with shows and ads, so I assume that's the reason the events are getting lost...

Paul

Reply

Hi Paul,

thanks for the quick reply. I've found a workaround with an combnination of playlist.onStart() and checking the clipType :)

Reply

Ah.. cool... to be honest, I've also been thinking if there is a way I can preserve all those attached events when OVA reschedules. There undoubtably is, I just need to do that... will try to sort that as well in the next check-in or two...

Paul

Reply

Is there any specia attribute/type on the PreRoll clip to determine if this is an preroll ad?

Reply

Hi,

Yes there are a few properties that OVA sets on the clip. In Flowplayer, these are set as "customProperties":

See section 22 of the RC5 release note:

http://developer.longtailvideo.com/ova/wiki/OvaReleaseNote-0.5.0-RC5

Paul

Post new comment

  • Allowed HTML tags: <code> <blockquote> <em> <strong> <strike> <ul> <li> <ol>
  • You may post code using <code>...</code> .
  • Lines and paragraphs break automatically.
  • Web page addresses and e-mail addresses turn into links automatically.

More information about formatting options