
天貓2015年1111優(yōu)惠券集合,一次性領(lǐng)完天貓雙十一所有優(yōu)惠券的方法!天貓雙十一活動已經(jīng)開始熱場,活動頁面也出來了,頁面有許多優(yōu)惠券,一個個領(lǐng)實在太麻煩,不如來試下下面這個方法,一次性將所有優(yōu)惠券都領(lǐng)了吧~
1、登陸天貓,打開雙十一活動頁面,右鍵選擇“審查元素”(chrome瀏覽器可以直接按F12) 2、點擊Console,然后在空白處將下面的代碼復(fù)制進(jìn)去,按回車就可以自動領(lǐng)券了
(function(window, document, undefined) {
var interval = 800;
var closeDelay = 200;
var index = 0;
var couponLinks;
var getCoupon = function() {
if (index >= couponLinks.length) {
console.log("領(lǐng)取完畢");
return;
}
var coponLink = couponLinks[index];
coponLink.click(); index++;
console.log("領(lǐng)取 第" + index + " 張");
setTimeout(getCoupon, interval);
setTimeout(function() {
var close = document.querySelector('.mui-dialog-close');
if (close != null) close.click();
}, closeDelay);
}
var _scrollTop = 0;
var _scrollStep = document.documentElement.clientHeight;
var _maxScrollTop = document.body.clientHeight - document.documentElement.clientHeight;
var autoScrollDown = setInterval(function() {
_scrollTop += _scrollStep;
if (_scrollTop > _maxScrollTop) {
clearInterval(autoScrollDown);
couponLinks = document.querySelectorAll('.mui-act-item-yhqbtn');
console.log("總共:" + couponLinks.length + "條張優(yōu)惠券待領(lǐng)取...");
getCoupon();
} else {
document.body.scrollTop = _scrollTop;
}
}, 500);
}) (window, document);
提醒:本方法風(fēng)險未知,有疑慮的小伙伴可以不嘗試,或者在領(lǐng)完后更改賬號密碼。
