石家庄铁道大学继续教育学院视频播放

实现石家庄铁道大学继续教育学院视频播放,视频暂停后自动播放,自动切换下一章节


    // ==UserScript==
    // @name         石家庄铁道大学继续教育学院视频播放
    // @namespace    http://tampermonkey.net/
    // @version      0.4
    // @description  实现石家庄铁道大学继续教育学院视频播放,视频暂停后自动播放,自动切换下一章节
    // @author       陈孤岛
    // @match        http://jxjy.stdu.edu.cn/*
    // @match        http://220.194.70.38/student/*
    // @icon         https://www.google.com/s2/favicons?domain=stdu.edu.cn
    // @grant        none
    // ==/UserScript==

    (function() {
        'use strict';

        // Your code here...
        let videodom=document.querySelector('video')
        setTimeout(function () {
     setInterval(function(){

       if(videodom!==null){
            if(videodom.ended==true){
              document.querySelector('#nextChapter').click()

            }
           if(videodom.paused==true){
              document.querySelector('.vjs-poster').click()}
        }
        }, 3000)}, 3000)








    })();