之前分享过苹果CMS dplayer播放器的整合教程,很多朋友反馈有问题,这次又去原创博客找到他的二次优化教程代码。
优化版2021-03-13更新说明
记忆播放可通过url传参设置,默认开启无需设置,当传nostorage=1时关闭(解析域名设置为/dplayer.php/?nostorage=1&url=)
播放器中的设置按钮改为倍速播放按钮,去掉页面全屏按钮
手机端添加双击暂时/播放功能,添加左右划屏快进\快退功能,全屏后默认横屏
播放器功能
支持格式:m3u8、mp4
播放记忆
P2P加速(去除在视频中P2P信息)
自动播放下一集(仅电脑端)
去掉弹幕(需要的自行去掉注释)
手机增加引导点击播放图片
使用方法
将文件上传到自己的网站(比如文件名叫dplayer.php,上传到根目录)
在苹果cms后台播放器设置中开启解析,解析域名设置为/dplayer.php/?url=
整合代码
<!DOCTYPE html> <html> <head> <title>dplayer增加记忆+P2P播放</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"><!-- IE内核 强制使用最新的引擎渲染网页 --> <meta name="renderer" content="webkit"> <!-- 启用360浏览器的极速模式(webkit) --> <meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0 ,maximum-scale=1.0, user-scalable=no"><!-- 手机H5兼容模式 --> <meta name="x5-fullscreen" content="true" ><meta name="x5-page-mode" content="app" > <!-- X5 全屏处理 --> <meta name="full-screen" content="yes"><meta name="browsermode" content="application"> <!-- UC 全屏应用模式 --> <meta name=”apple-mobile-web-app-capable” content=”yes”> <meta name=”apple-mobile-web-app-status-bar-style” content=”black-translucent” /> <!-- 苹果全屏应用模式 --> <link rel="stylesheet" /> </head> <body style="background:#000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" oncontextmenu=window.event.returnValue=false> <div id="dplayer"></div> <div id="stats"></div> <div id="play_icon"></div> <script src="https://cdn.jsdelivr.net/npm/cdnbye@latest"></script> <script src="https://cdn.jsdelivr.net/npm/dplayer@latest"></script> <style type="text/css"> body,html{width:100%;height:100%;background:#000;padding:0;margin:0;overflow-x:hidden;overflow-y:hidden} *{margin:0;border:0;padding:0;text-decoration:none} #stats{position:fixed;top:5px;left:10px;font-size:10px;color:#fdfdfd;z-index:20719029;text-shadow:1px 1px 1px #000, 1px 1px 1px #000} #dplayer{position:inherit} .dplayer-menu.dplayer-menu-show{display:none} #play_icon { background-color: black; height:100%; background-image: url("data:image/gif;base64,R0lGODlhxgL0AdUAANzc3NLS0sTExLu7u7Ozs6urq6Ojo5mZmZGRkZCQkI6OjoaGhoWFhX19fXx8fHNzc3FxcWpqamRkZGBgYFhYWFZWVk1NTUxMTERERENDQz4+Pjo6OjAwMC4uLiYmJh0dHRoaGhMTEwoKCgQGBwAAAP4BAgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQFFAAlACwAAAAAxgL0AQAG/0CScEgsGo/IpHLJbDqf0Kh0Sq1ar9isdsvter/gsHhMLpvP6LR6zW673/C4fE6v2+/4vH7P7/v/gIGCg4SFhoeIiYqLjI2Oj5CRkpOUlZaXmJmam5ydnp+goaKjpKWmp6ipqqusra6vsLGys7S1tre4ubq7vL2+v8DBwsPExcbHyMnKy8zNzs/Q0dLT1NXW19jZ2tvc3d7f4OHi4+Tl5ufo6err7O3u7/Dx8vP09fb3+Pn6+/z9/v8AAwocSLCgwYMIEypcyLChw4cQI0qcSLGixYsYM2rcyLGjx48gQ4ocSbKkyZMoU6pcybKly5cwY8qcSbOmzZs4c+rcybOnz/+fQIMKHUq0qNGjSJMqXcq0qdOnUKNKnUq1qtWrWLNq3cq1q9evYMOKHUu2rNmzaNOqXcu2rdu3cOPKnUu3rt27ePPq3cu3r9+/gAMLHky4sOHDiBMrXsy4sePHkCNLnky5suXLmDNr3sy5s+fPoEOLHk26tOnTqFOrXs26tevXsGPLnk27tu2pHSBA6KClw4ULXUBIQEBAQAABBBBIA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q+kpYqytZojnMIFxIaHx6VojY6QuFpG3N3e3+Dh4t/Ni0bNQQAh+QQFFAAlACxHAWMBOwALAAAGp0CDcEgkkRjIpNIoaTqfRox0SjUGAoBrFhsgFQzfMNhgVJoZzKc6Sm0bt/BrdywOl8/JtNrJbk+tcVwAJESFZEd4SHp7En1+GCQjWoJchHV0d4mLe45+gJSVl2KZeJtrJI9/JIFbc4ZDpGemUKipkCRck1mDomOxZrN8talWoJV0yAW/SySMwra3lLtXI6+wiJrNzo3Dj2+TlEaRRiPk4ufo6err7OtBADs="); background-size: contain; background-repeat: no-repeat; background-position: center; display:flex; align-items: center; position: absolute; top: 0px; left: 0px; width: 100%; z-index: 999; } #play_icon img { width:10%; margin-left: 45%; } </style> <script> var url = '<?php echo($_REQUEST['url']);?>'; var url = '<?php echo($_REQUEST['url']);?>'; var nostorage = '<?php echo($_REQUEST['nostorage']);?>'; var isWap = navigator.userAgent.match(/iPad|iPhone|iPod|Baidu/i) != null; //百度浏览器和苹果移动端不使用P2P功能 var isMobile = !!navigator.userAgent.match(/AppleWebKit.*Mobile.*/); //是否手机端 if(!isWap){ if(url.indexOf(".m3u8") > 0){ var _peerId = '', _peerNum = 0, _totalP2PDownloaded = 0, _totalP2PUploaded = 0; var type = 'customHls'; } else { var type = 'normal'; //MP4格式P2P兼容性不好,不调用P2P。 } var dp = new DPlayer({ container: document.getElementById('dplayer'), autoplay: false, hotkey: true, // 移动端全屏时向右划动快进,向左划动快退。 airplay: true, logo: '', video: { url:url, pic: '', //图片地址。 type: type, customType: { 'customHls': function (video, player) { const hls = new Hls({ debug: false, p2pConfig: { logLevel: true, live: false, // 如果是直播设为true } }); hls.loadSource(video.src); hls.attachMedia(video); hls.p2pEngine.on('stats', function (stats) { _totalP2PDownloaded = stats.totalP2PDownloaded; _totalP2PUploaded = stats.totalP2PUploaded; //updateStats(); }).on('peerId', function (peerId) { _peerId = peerId; }).on('peers', function (peers) { _peerNum = peers.length; //updateStats(); }); } } }, /*danmaku: { id: 'E3368B56CDBB4IU', //弹幕代码,可定义其他的ID,请修改; api: 'https://dplayer.moerats.com/', bottom: '25%', unlimited: false, }, */ contextmenu: [ ], highlight: [ { text: '提示:点击下方状态栏可以发送字幕', time: 360, }, { text: '警告:请不要相信视频中任何广告与字幕', time: 1200, }, ], }); var webdata = { set:function(key,val){ window.sessionStorage.setItem(key,val); }, get:function(key){ return window.sessionStorage.getItem(key); }, del:function(key){ window.sessionStorage.removeItem(key); }, clear:function(key){ window.sessionStorage.clear(); } }; if (!nostorage) { dp.seek(webdata.get('vod'+url)); setInterval(function(){ webdata.set('vod'+url,dp.video.currentTime); },1000); } dp.on('ended',function() { dp.notice("视频播放已结束"); //可以替换成下一集调用等代码 if(parent.MacPlayer.PlayLinkNext!=''){ top.location.href = parent.MacPlayer.PlayLinkNext; } }); if (isMobile) { //全屏事件 dp.on('fullscreen',function() { screen.orientation.lock("landscape"); }); //退出全屏事件 dp.on('fullscreen_cancel',function() { screen.orientation.unlock(); }); //左右滑动快进、后退 let touchPointX = 0; let touchPointY = 0; let currentTime = 0; let isSeeked = false; document.addEventListener('touchstart', e => { let touch = e.touches[0]; touchPointX = touch.clientX; // 获取触摸的初始位置 touchPointY = touch.clientY; currentTime = dp.video.currentTime; // 获得当前播放时间 }); document.addEventListener('touchmove', e => { let touch = e.touches[0]; let diffX = touch.clientX - touchPointX; // 通过当前位置与初始位置之差计算改变的距离 let diffY = touch.clientY - touchPointY; let totalTime = dp.video.duration; if (Math.abs(diffX) > Math.abs(diffY) && Math.abs(diffX) > 5) { let seekTime = parseInt(currentTime + diffX); // 计算出快进时间 if (seekTime < 0) { seekTime = 0; } if (seekTime > totalTime) { seekTime = totalTime; } dp.seek(seekTime); isSeeked = true; } let notice = document.getElementsByClassName("dplayer-notice"); if (notice.length > 0) { notice[0].style.display = "none"; } }); document.addEventListener('touchend', e => { if (isSeeked) { let touch = e.changedTouches[0]; let diffX = touch.clientX - touchPointX; let notice = document.getElementsByClassName("dplayer-notice"); if (notice.length > 0) { notice[0].style.display = "block"; } dp.notice((diffX>0?"快进":"快退") + parseInt(Math.abs(diffX)) + "秒", 2000); } isSeeked = false; }); } } else{ document.getElementById('dplayer').innerHTML='<video src="'+url+'" controls="controls" preload="preload" poster="" width="100%" height="100%"></video>'; } function updateStats() { var text = '七星P2P正在为您加速' + (_totalP2PDownloaded/1024).toFixed(2) + 'MB 已分享' + (_totalP2PUploaded/1024).toFixed(2) + 'MB' + ' 连接节点' + _peerNum + '个'; document.getElementById('stats').innerText = text ; } </script> <script> var video = document.getElementsByTagName('video')[0]; //添加引导点击播放图片 var img = new Image(); img.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAACXBIWXMAAAsSAAALEgHS3X78AAAMWElEQVR42u1db0gjZxofJ2E1JiH/TGxMwDObP9L20wq93hW5WLLcIkpZrKCu0MUFu0TbL1KhcMdmuQ+F9NwPdi1dyy0WWlewfija4tHQZFl61yunn9aSmOzkAhOzGvOPTDImZPQ+rCnj6+RfTTKTZJ6PrzNx5vnN83ue93nf93maTk5OIAaLGEGQP/J4vCtcLrertbX1VRiGRTwez1DMzTiOu46Pj2PJZPJpJpPx4ji+ffny5X+enJwQTH3hJiYB4nQ6ZTwe71pra+ubAoHgjWIVX6rgOO7CMOzHZDL5A47jm93d3SEWEBIIAoFgVCgUviUSiUx0PEMsFrPF4/FvMAx7RDc4tAGCIEi/WCyekEqlQ0yijHA4vBaNRh9qNJrvGgIQFEWnZTLZdCl0RBAEFo/Hd8PhsOvo6Cju8Xh2I5FIPN89EolEqNVq9S0tLUKpVGoQCoV6DocjKIXWQqHQfbVafb8uAUFRdFqhUHx46dKljkLXplKpwOHh4Zbb7d5aXV3d+vTTT/fK8Qxms7ljeHi4R6fT9bS1tfU0NzcrC92TTqf3Dg4OPqoWMBUHBEGQ/vb29jt8Pv+1QiD4/X7H2tra+uzs7G41Xt5qteqHhoYGVSqVsRA4iUTi5/39/buVprKKAeJ0OmUKheJBIR/h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eUD5/DwcMvtdm+trq5ulSsQMJvNHcPDwz06na6nra2tpxAIEPRid8jBwcFHFw1nGQcIGRiZTDadKxrLxdnxeHw3HA67jo6O4h6PZ7dQoTWJRCLUarX6lpYWoVQqNQiFQn0un5AregqFQverBQRtgJCpTCwWT4B7iemWcDi8Fo1GH1aamhgHCNn5CwSCUaFQ+BbYoaFaEovFbPF4/BsMwx5VylnXDCAgODwe71pra+ubAoHgjVJorRTBcdyFYdiPyWTyBxzHN+kGgbGA5KI2Ho93hcvldp3WtRUVCxSO467j4+NYMpl8mslkvDiOb9NFRcXK/wG7viMTqo7LKQAAAABJRU5ErkJggg=="; document.getElementById("play_icon").appendChild(img); video.setAttribute("playsinline", "true"); video.setAttribute("webkit-playsinline", "true"); video.setAttribute("x5-video-player-type", "h5"); video.setAttribute("x5-video-player-fullscreen", "false"); var state = 0; video.onplaying = function(){ var icon = document.getElementById("play_icon"); if (icon) { icon.remove() } state=1; }; video.onplay = function(){ var icon = document.getElementById("play_icon"); if (icon) { icon.remove() } state=1; }; video.onpause = function(){ state = 0; }; var playIcon = document.getElementById("play_icon"); if (playIcon.addEventListener) { playIcon.addEventListener('click', function(){ if(state==0){ video.play(); }else { video.pause(); } }, false); } document.addEventListener('dblclick', function(){ if(state==0){ video.play(); }else { video.pause(); } }, false); document.addEventListener("WeixinJSBridgeReady", function () { video.play(); }, false); //把设置按钮改为速播 var settingIcon = document.getElementsByClassName("dplayer-setting-icon")[0]; settingIcon.innerHTML="倍速"; settingIcon.style.outline="none"; settingIcon.style.color="white"; settingIcon.style.padding="0 5px"; var speedIcon = document.getElementsByClassName("dplayer-setting-speed")[0]; settingIcon.onclick = function(){ speedIcon.click(); //速度选择框为横向显示 document.getElementsByClassName("dplayer-setting-box-speed")[0].style.width = "300px"; var speendItems = document.getElementsByClassName("dplayer-setting-speed-item"); for (let i=0; i<speendItems.length; i++) { speendItems[i].style.display = "inline"; } }; //去掉页面全屏按钮 document.getElementsByClassName("dplayer-full-in-icon")[0].remove(); </script> </body> </html>
资源均来自第三方,谨慎下载,前往第三方网站下载