Example 1 - A pre-roll ad only

This will be replaced by the SWF.

The configuration for this example is:


<script type="text/javascript">
   function buildOVAConfiguration() {
      var result = '';
      var OAS_url = 'http://oasc16.247realmedia.com/RealMedia/ads/adstream_sx.ads';
      var OAS_sitepage = 'openvideoads.org/vast';
      var OAS_listpos = 'x01';
      OAS_rdl = OAS_rdl != '' ? OAS_rdl.split("&")[1] : '';
      
      result += '{"blockUntilOriginalPlaylistLoaded":true,';
      result += '"debug":{';
      result += '"debugger":"firebug",';
      result += '"levels":"fatal, config, vast_template"';
      result += '},';
      result += '"ads":{';
      result += '"pauseOnClickThrough":true,';
      result += '"servers":[';
      result += '{';
      result += '"type":"OAS",';
      result += '"apiAddress":"' + OAS_url + '",';
      result += '"customProperties":{';
      result += '"target":["overlay","XE","' + OAS_rdl + '", "if_nt_CookieAccept=\'' + OAS_CA + '\","XE"]';
      result += '}';
      result += '}';
      result += '],';
      result += '"schedule":[';
      result += '{';
      result += '"zone":"' + OAS_sitepage + '@' + OAS_listpos + '",';
      result += '"position":"pre-roll"';
      result += '}';
      result += ']';
      result += '}}';
      return escape(result);
   }

   var flashvars = {
      'plugins':    	OVA_PLUGIN_3,
      'playlist':   	'none',
      'repeat':         'list',
      'autostart':      'false',
      'dock':           'true',
      'frontcolor':     'ffffff',
      'title':          'Big%20Buck%20Bunny%20Trailer',
      'image':          'http://content.bitsontherun.com/thumbs/nPripu9l-480.jpg',
      'stretching':     'uniform',
      'ping.script':	'http://content.bitsontherun.com/pings/',
      'lightcolor':     '009999',
      'controlbar':     'over',
      'displayclick':	'play',
      'backcolor':      '000000',
      'playlistsize':	'200',
      'skin':           'http://content.bitsontherun.com/skins/VFgGj89b.swf',  
      'file':           'http://content.bitsontherun.com/jwp/nPripu9l.xml',
      'ova.json':       buildOVAConfiguration()
   };

   var params = {
      'allowfullscreen':    'true',
      'allowscriptaccess':  'always',
      'bgcolor':            '#000000'
   };

   var attributes = {
      'id':                 'player1',
      'name':               'player1'
   };

   swfobject.embedSWF(OVA_PLAYER_3, 'player', '480', '272', '9', 'false', flashvars, params, attributes);
</script>