Skip to content

Commit

Permalink
优化 自动签到方式(改为后台打开签到地址并立即关闭,不影响前台观感)
Browse files Browse the repository at this point in the history
  • Loading branch information
XIU2 committed Feb 28, 2021
1 parent ebd3090 commit a337525
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions 52pojie-Enhanced.user.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// ==UserScript==
// @name 吾爱破解论坛增强 - 自动签到、翻页
// @version 1.2.0
// @version 1.2.1
// @author X.I.U
// @description 自动签到、自动无缝翻页(全站)
// @match *://www.52pojie.cn/*
Expand Down Expand Up @@ -150,7 +150,8 @@
// 搜索结果列表
curSite = DBSite.search;
}else if(location.href === "https://www.52pojie.cn/home.php?mod=task&do=draw&id=2"){
qianDaoBack(); // 先看看是不是签到跳转页面,如果是则返回
window.opener=null;window.open('','_self');window.close();
//qianDaoBack(); // 先看看是不是签到跳转页面,如果是则返回
}
curSite.pageUrl = ""; // 下一页URL

Expand Down Expand Up @@ -186,10 +187,12 @@
function qianDao() {
var qiandao = document.querySelector('#um p:last-child a:first-child');
if (qiandao){
if(qiandao.href === "https://www.52pojie.cn/home.php?mod=task&do=apply&id=2")
{
qiandao.click();
}
//if(qiandao.href === "https://www.52pojie.cn/home.php?mod=task&do=apply&id=2")
//{
window.GM_openInTab(qiandao.href, {active: false,insert: true,setParent: true}) // 后台打开签到地址
qiandao.querySelector('.qq_bind').setAttribute('src','https://www.52pojie.cn/static/image/common/wbs.png') // 修改 [打卡签到] 图标为 [签到完毕]
//qiandao.click();
//}
}
}

Expand Down

0 comments on commit a337525

Please sign in to comment.