您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Greasy Fork is available in English.
对于评教只能用IE的BUG进行了修复,现在可以用任何浏览器进行访问.能自动选择
// ==UserScript== // @name 南京理工大学自动评教 // @namespace LordCasser // @version 0.2 // @description 对于评教只能用IE的BUG进行了修复,现在可以用任何浏览器进行访问.能自动选择 // @author LordCasser // @match http://202.119.81.113:9080/njlgdx/xspj/xspj_list.do* // @match http://202.119.81.113:9080/njlgdx/xspj/xspj_edit.do* // @match http://202.119.81.113:9080/njlgdx/kscj/cxbmxk_query* // @run-at document-end // @require https://code.jquery.com/jquery-1.12.4.min.js // @grant window.open // @grant replace // @grant window.location.pathname // ==/UserScript== $(document).ready(function(){ function replace_judge_href (){ var tmp = $("a[href]"); for(var i =12; i < tmp.length ;i++){ var t = $($("a[href]")[i]).attr("href"); t = t.replace("JsMod","window.open"); $($("a[href]")[i]).attr("href",t); } } function set_radios(){ var but = $(":radio"); for(var i=0;i <but.length;i=i+5){ if (i == but.length-5) { i++; } $(but[i]).attr({checked:"checked"}); } } function replace_buttun_herf(){ var tmp = $("input[onclick]"); for (var i=0;i < tmp.length;i++){ var t = $($("input[onclick]")[i]).attr("onclick"); t = t.replace("JsMod","window.open"); $($("input[onclick]")[i]).attr("onclick",t); } } function run(){ var path = window.location.pathname; if(path == "/njlgdx/xspj/xspj_list.do") { replace_judge_href(); } else if (path == "/njlgdx/xspj/xspj_edit.do"){ set_radios(); } else if (path == "/njlgdx/kscj/cxbmxk_query"){ replace_buttun_herf(); } } run(); });