您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Greasy Fork is available in English.
实现天职大校园网自动登陆。
当前为
// ==UserScript== // @name 天职大校园网自动登陆工具 // @version 1.0 // @description 实现天职大校园网自动登陆。 // @author Interpret // @match *://172.21.36.1/* // @grant none // @namespace tjtclogin // @license MIT // @run-at document-end // @grant unsafeWindow // @grant GM_xmlhttpRequest // @grant GM_setClipboard // ==/UserScript== (function (){ 'use strict'; //用户自定义 var user="学号" var pwd="密码" var yys="1" //1为登录电信互联网,0为登录职大校园网。 var run="0" //1为启用自动登陆,0为不启用只填写账号密码。 //代码部分,如不了解请勿随意修改! window.onload = function() { if(document.title=="上网登录页") { document.getElementsByClassName("edit_lobo_cell")[1].value=user document.getElementsByClassName("edit_lobo_cell")[2].value=pwd if (yys=1) { document.getElementsByClassName("edit_lobo_cell")[5].value="@tjtc" } else { if (yys=0) { document.getElementsByClassName("edit_lobo_cell")[5].value="" } } if (run=1) { setTimeout(document.getElementsByClassName("edit_lobo_cell")[0].click(), 5000) } } if(document.title=="登录成功页") { alert("自动登录成功,点击确定关闭本页");window.close(); } if(document.title=="注销页") { var tip2=document.getElementsByClassName("edit_lobo_cell")[1]; tip2.style="left: 32px; top: 7px; width: 440px; height: 50px; text-align: center; color: rgb(51, 51, 51); font-size: 19px; box-shadow: 0px 0px 0px #322f2f; background-color: rgba(0, 0, 0, 0);"; tip2.lastElementChild.outerHTML='<a href="https://shimo.im/docs/jwct6gw8WWYvPrgR/" target="_blank"><p>使用说明点击这里☜<br><br></p></a>'; } } })();