New Userscript

英盛网刷课脚本

K instalaci tototo skriptu si budete muset nainstalovat rozšíření jako Tampermonkey, Greasemonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

K instalaci tohoto skriptu si budete muset nainstalovat manažer uživatelských skriptů.

(Už mám manažer uživatelských skriptů, nechte mě ho nainstalovat!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Už mám manažer uživatelských stylů, nechte mě ho nainstalovat!)

// ==UserScript==
// @name         New Userscript
// @namespace    http://tampermonkey.net/
// @version      2025-01-24
// @author       howardnm
// @description  英盛网刷课脚本
// @license MIT
// @match        https://qy.yingsheng.com/*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=yingsheng.com
// @grant        none
// ==/UserScript==

const selector = 'a[data-v-8ae46a44][data-dismiss="modal"]';

let checkInterval = setInterval(() => {
    const button = document.querySelector(selector);
    if (button) {
        console.log('找到按钮:', button);
        setTimeout(() => {
            button.click();
            console.log('按钮已点击');
            // clearInterval(checkInterval); // 点击后停止轮询
        }, 2000); // 延迟 2 秒后点击
    } else {
        console.log('仍未找到按钮,继续检查...');
    }
}, 1000); // 每隔 1 秒检查一次