javascript - 无法在 VAST - FLUID PLAYER 中显示“跳过广告”
问题描述
BASE-我正在开发一个视频播放器项目。我在将 VAST 与其集成时遇到问题。
我无法显示 SKIP AD 按钮。
我正在使用FLUID PLAYER。文档 链接- https://docs.fluidplayer.com/docs/configuration/ads/
我正在使用以下代码-
<script src="https://cdn.fluidplayer.com/v3/current/fluidplayer.min.js"></script>
<video id="video-id">
<source
src="https://7yotyu1slxwgqeaj4md7bg-on.drv.tw/TM%20media/TM_Vids/Blacked%20%E2%80%93%20Hot%20Southern%20Blonde%20Takes%20Big%20Black%20Cock%20%E2%80%93%20Cherie%20Deville,%20Prince%20Yahshua.mp4"
type="video/mp4" />
<script>
var myFP = fluidPlayer(
'video-id', {
"layoutControls": {
"controlBar": {
"autoHideTimeout": 3,
"animated": true,
"autoHide": true
},
"htmlOnPauseBlock": {
"html": null,
"height": null,
"width": null
},
"autoPlay": true,
"mute": false,
"allowTheatre": true,
"playPauseAnimation": true,
"playbackRateEnabled": true,
"allowDownload": false,
"playButtonShowing": true,
"fillToContainer": true,
"posterImage": ""
},
"vastOptions": {
"allowVPAID": true, // Default false.
"adList": [
{
"roll": "preRoll",
"vastTag": "https://www.videosprofitnetwork.com/watch.xml?key=0185fa78fd7a7789bf1d0ac524fec3f4",
"adText": ""
},
{
"roll": "midRoll",
"vastTag": "https://www.videosprofitnetwork.com/watch.xml?key=0185fa78fd7a7789bf1d0ac524fec3f4",
"adText": ""
},
{
"roll": "postRoll",
"vastTag": "https://www.videosprofitnetwork.com/watch.xml?key=0185fa78fd7a7789bf1d0ac524fec3f4",
"adText": ""
}
],
"skipButtonCaption": 'Skip ad in [seconds]',
"skipButtonClickCaption": 'Skip ad <span class="skip_button_icon"></span>',
"adText": null,
"adTextPosition": 'top left',
"adCTAText": 'Visit now!',
"adCTATextPosition": 'bottom right',
"vastTimeout": 5000,
"showPlayButton": false,
// maxAllowedVastTagRedirects: 1,
}
})
</script>
</div>
<!-- end video player -->
特别是这个 JSON-
"vastOptions": {
"allowVPAID": true, // Default false.
"adList": [
{
"roll": "preRoll",
"vastTag": "https://www.videosprofitnetwork.com/watch.xml?key=0185fa78fd7a7789bf1d0ac524fec3f4",
"adText": ""
},
{
"roll": "midRoll",
"vastTag": "https://www.videosprofitnetwork.com/watch.xml?key=0185fa78fd7a7789bf1d0ac524fec3f4",
"adText": ""
},
{
"roll": "postRoll",
"vastTag": "https://www.videosprofitnetwork.com/watch.xml?key=0185fa78fd7a7789bf1d0ac524fec3f4",
"adText": ""
}
],
"skipButtonCaption": 'Skip ad in [seconds]',
"skipButtonClickCaption": 'Skip ad <span class="skip_button_icon"></span>',
"adText": null,
"adTextPosition": 'top left',
"adCTAText": 'Visit now!',
"adCTATextPosition": 'bottom right',
"vastTimeout": 5000,
"showPlayButton": false,
// maxAllowedVastTagRedirects: 1,
}
我仍然没有得到跳过广告按钮。有人可以帮忙吗?