您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
补选南京大学的通识课(上)
当前为
// ==UserScript== // @name njuCoursesPart1 // @namespace http://handsomeone.com // @description 补选南京大学的通识课(上) // @include http://*.nju.edu.cn:8080/jiaowu/student/elective/courseList.do?method=discussRenewCourseList&campus=* // @version 2 // @grant none // ==/UserScript== domain = window.location.hostname.slice(0, - 11); inputs = document.getElementsByTagName('input'); campus = document.getElementById('campusList').options[document.getElementById('campusList').selectedIndex].value; if (inputs.length == 1) { window.location.href = 'http://' + domain + '.nju.edu.cn:8080/jiaowu/student/elective/courseList.do?method=discussRenewCourseList&campus=' + campus; } else { luck = inputs[parseInt(Math.random() * (inputs.length - 1))]; name = luck.parentNode.parentNode.childNodes[2].innerHTML; if (localStorage.i) { localStorage.i = eval(localStorage.i) + 1; localStorage.n += ' ' + name; } else { localStorage.i = 1; localStorage.n = name; } window.location.href = 'http://' + domain + '.nju.edu.cn:8080/jiaowu/student/elective/courseList.do?method=submitDiscussRenew&classId=' + luck.value + '&campus=' + campus; }