video标签不写controls属性
就不会显示 播放 / 暂停 / 以及滚动条
自定义添加2个按钮 控制播放和暂停
<body>
<div class="box">
<video id="video" src="xxxxxxx.mp4" autoplay width="300" height="275"></video>
<div>
<button id="startPlay">播放</button>
<button id="stopPlay">暂停</button>
</div>
</div>
</body>
window.onload=function(){
var video=document.getElementById("video");
var startPlay=document.getElementById('startPlay');
var stopPlay=document.getElementById('stopPlay');
startPlay.addEventListener('click',function() {
video.play();
});
stopPlay.addEventListener('click',function() {
video.pause();
});
}