微信浏览器视频播放完后,自动跳qq浏览器得解决方法


html:
<video id="my-video" class="video-js " controls 
               poster="{{tuUrl}}" controlslist="nodownload" id='end' src="{{safeUrl}}">
          </video>
js:
doms;
showOtherVideo() {
    let _this = this;
    let dom = document.getElementById('end');
    this.doms = document.getElementById('end');
    const time= setTimeout(function(){
      console.log(dom['currentTime']);
    if(!dom['paused']){
       _this.showOtherVideo();
      }else{
        if(dom['currentTime'] == dom['duration'] &&dom['currentTime']!=0) {
          window.location.reload();
        } else {
          _this.showOtherVideo();
        }
      }
   },1000)
  }
只要用了video标签,在微信浏览器中播放完视频,都会被qq浏览器捕获到。所以只能监听该视频是否播放完,进行处理。


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM