Example 1.04.02 - VAST1 + VAST 2 Wrapper Impression, Click and Event Tracking Callbacks

Loading the player ...

The configuration for this example is:


<script type="text/javascript">

function onImpressionEvent(event, forced) {
    if(forced) {
       debug("OVA CALLBACK: Forced impression fired");
    }
    else debug("OVA CALLBACK: Impression fired");
	debug(event);
}

function onTrackingEvent(event) {
	debug("OVA CALLBACK: Tracking event fired");
	debug(event);
}

function onClickTrackingEvent(event) {
	debug("OVA CALLBACK: Click tracking event fired");
	debug(event);
}

function onCustomClickTrackingEvent(event) {
	debug("OVA CALLBACK: Custom click tracking event fired");
	debug(event);
}

jwplayer("container").setup({
       flashplayer: "", 

       width: 650,
       height: 240,

       controlbar: "bottom",

       playlist:[
           { 
               file: "http://streaming.openvideoads.org/shows/bbb-640x360.mp4",
               duration: 10
           }
       ],

       plugins: {
           "../../../dist/swf/ova-jw.swf": { 
               "canFireEventAPICalls": true,
               "ads": {
                   "companions": {
                       "regions": [
                           { "id":"companion", "width":"300", "height":"250" }
                       ]
                   },
                   "notice": { "textStyle": "smalltext" },
                   "schedule": [
                       {
                           "position": "pre-roll",
                           "tag": "../../../dist/templates/wrapper/vast1-wrapper-to-vast2-wrapper-vast1-ad.xml"
                       }
                   ]
               },

               "debug": {
                  "levels": "fatal, config, vast_template, vpaid, http_calls, playlist, api"
               }
           }
       }
});
</script>