Greasy Fork is available in English.
安徽奥鹏暑假视频学习, 视频中会不间断跳出题目, 此插件可自动选择答题项并提交(默认选C项, 不保证答题正确), 不需要再手动答题
当前为
// ==UserScript==
// @name 奥鹏自动答题
// @namespace http://tampermonkey.net/
// @description 安徽奥鹏暑假视频学习, 视频中会不间断跳出题目, 此插件可自动选择答题项并提交(默认选C项, 不保证答题正确), 不需要再手动答题
// @author SkuraZZ
// @version 2024.7.23.1
// @match https://learn.ourteacher.com.cn/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=ourteacher.com.cn
// @grant none
// @license MIT
// ==/UserScript==
(function() {
'use strict';
document.addEventListener('DOMContentLoaded', (event) => {
var video = document.getElementById('ckplayer_video');
video.loop = true;
});
(function checkAndClickElementsInIframe() {
setInterval(() => {
const iframes = document.getElementsByTagName('iframe');
for (let i = 0; i < iframes.length; i++) {
try {
const iframeDocument = iframes[i].contentDocument || iframes[i].contentWindow.document;
const radioButtonC = iframeDocument.getElementById('radiobuttonC');
if (radioButtonC) {
radioButtonC.click();
const submitButton = iframeDocument.getElementById('submit');
if (submitButton) {
submitButton.click();
console.log("已答题", Date())
}
}
} catch (e) {
console.warn('Unable to access iframe content:', e);
}
}
}, 20000); // Every 20s
})();
console.log("奥鹏test")
// Your code here...
})();