Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

Code not working(ad is not loading main video is coming when we refresh the page)


<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.2/jquery.min.js"></script>
<script src="http://content.jwplatform.com/libraries/CNCV8UzO.js"></script>


<script>jwplayer.key="8mFq0bNgddGCCizDr5iI4dFvvWU9kR7MUS0TAg==";</script>


</head>
<body>
<div id="my-video"></div>
<script type="text/javascript">
jwplayer("my-video").setup({
file: "any video",
image: "http://content.jwplatform.com/thumbs/Wf8BfcSt-640.jpg",
width: "580",
height: "370",
primary: "html5",
advertising: {
client: "vast",
schedule:{
adbreak1: {
offset: "pre",
tag: "http://demo.jwplayer.com/advertising/assets/vast3_jw_ads.xml"
}
}
},
events: {
onTime: function() {
var viewdDuration = jwplayer().getPosition();
if (viewdDuration >= 10 ) {
jwplayer("my-video").playAd("http://demo.jwplayer.com/advertising/assets/vast3_jw_ads.xml");
}
}
}

});
</script>
</body>
</html>

1 Community Answers

Donni

JW Player Support Agent  
0 rated :

You will need to purchase an ads license in order to play ads on your videos.

This question has received the maximum number of answers.