采用flv.js与dplayer播放器来播放http-flv格式视频

 

 

实现代码

<div id="dplayer"></div>
<script src="https://cdn.jsdelivr.net/npm/flv.js@1.5.0/dist/flv.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/dplayer@1.25.1/dist/DPlayer.min.js"></script>
<script>
    var dp = new DPlayer({
        container: document.getElementById('dplayer'),  //播放器容器
        screenshot: true,  //截图功能
        video:{
            url : 'http://192.168.31.66:9999/<%=str%>',
        }
    });
</script>

 

参考

https://blog.csdn.net/weixin_44890856/article/details/106046403

上一篇:704. 二分查找


下一篇:SQL8 找出所有员工当前薪水salary情况