Flowplayer · TrueView skippable video advert

This is a TrueView skippable video advert.

These kind of ads are often seen in YouTube. Learn more about TrueView skippable video ads.

JavaScript install alternative

Note:

See the AdSense for video and games policies for details.

Video adverts depend on what is available in the AdSense inventory and your region. Sometimes there may be no video advert matching the current criteria and then no advert will be shown here.

<head/>

Include the ASF assets after loading all other Flowplayer assets:

<!-- Flowplayer -->
<script src="//releases.flowplayer.org/7.1.0/flowplayer.min.js"></script>
 
<!-- Flowplayer hlsjs plugin -->
<script src="//releases.flowplayer.org/hlsjs/flowplayer.hlsjs.min.js"></script>
 
<!-- Google IMA SDK -->
<script src="//imasdk.googleapis.com/js/sdkloader/ima3.js"></script>
<!-- Flowplayer ASF plugin -->
<script src="//releases.flowplayer.org/asf/flowplayer.org/2.1.8/asf.min.js"></script>

HTML

asf.min.js is the AdSense plugin for Flowplayer - you will get your own version of it when you sign up with our AdSense program. This plugin will be tied to your personal ad slot so that the ad impressions and clicks will be associated with your account, and the ad revenue will be assigned to you.

This page uses //releases.flowplayer.org/asf/flowplayer.org/2.1.8/asf.min.js which was built for the flowplayer.org domain and its subdomains. Make sure you are using the build we created for you, otherwise you will not see any revenues.

.flowplayer {
background-image: url(//flowplayer.com/media/img/logo-blue.png);
background-size: 95%;
background-color: #fff !important;
-webkit-box-shadow: 0 0 20px #b8b8b8;
-moz-box-shadow: 0 0 20px #b8b8b8;
box-shadow: 0 0 20px #b8b8b8;
}

CSS

<script>

// set up ASF pre-roll for all players on the page
flowplayer.conf.ima = {
// this should only be set when you are testing your installation
// adtest: true,
 
// make the Google robots crawl the current page
description_url: location.href,
 
// adverts configuration
ads: [{
// pre-roll ...
time: 0,
 
// ... of type skippablevideo
ad_type: "skippablevideo"
}]
 
};
 

window.onload = function () {
 
// install player as usual once DOM is ready
flowplayer("#player", {
ratio: 9/16,
splash: true,
clip: {
sources: [
{ type: "application/x-mpegurl",
src: "//edge.flowplayer.org/FlowplayerHTML5forWordPress.m3u8" },
{ type: "video/mp4",
src: "//edge.flowplayer.org/FlowplayerHTML5forWordPress.mp4" }
]
}
});
 
};

JavaScript

<body/>

Just the container element is needed here, the rest is left to the script above.

<div id="player"></div>

HTML

ad_type

ad_type is "skippablevideo" and it is positioned at time zero, which makes it a pre-roll.

ad_type defines what types of ads will be requested and shown. Here we only show skippablevideo adverts. If you don't specify the ad_type value at all it will show video, image and text ads because the default ad_type value is "video_image_text".

AdSense for Flowplayer demos