Last active
June 24, 2016 08:25
-
-
Save youminkim/60ac9b76502f48370240 to your computer and use it in GitHub Desktop.
Pinterest Hack
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var seconds = 3600/100; // hour limit 300 | |
var move = 150; | |
// selectors | |
var sel_like = 'button.LikeButton.rounded.PinLikeButton.Button:not(.unlike)'; | |
var sel_board = 'Button.hasText.btn.rounded.Button.boardFollowUnfollowButton:not(.dim)'; | |
var sel_follow = 'button.UserFollowButton.btn.rounded.Button:not(.dim)'; | |
function click(sel, n){ | |
e=document.createEvent('HTMLEvents'); | |
e.initEvent('click',true,true); | |
bs=document.querySelectorAll(sel)[0].dispatchEvent(e); | |
console.log(n); | |
window.scroll(0,n*move); | |
setTimeout(function() { | |
click(sel, n+1); | |
}, seconds*1000); | |
} | |
//click(sel_follow, 0); | |
//click(sel_board, 0); | |
//click(sel_like, 0) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var addresses = [ ... ]; | |
function invite(address){ | |
b=document.querySelectorAll('button.medium.rounded.Button.hasText.Module.inviteEmailButton')[0] | |
i=document.querySelectorAll('input.emailInput')[0] | |
i.value = address | |
b.className = b.className.replace("disabled", ""); | |
b.disabled = false; | |
e=document.createEvent('HTMLEvents'); | |
e.initEvent('click',true,true); | |
b.dispatchEvent(e); | |
console.log(address); | |
} | |
function start_invite(){ | |
var seconds = 3600/300; // hour limit 300 | |
for (var count = 0; count < addresses.length; count++){ | |
(function(){ | |
var i = count; | |
setTimeout(function() { | |
invite(addresses[i]); | |
}, seconds*i*1000); | |
}()); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I could not work it, can you help me about it.
Im trying like this;
var seconds = 60/10; // hour limit 300
var move = 15;
// selectors
var sel_follow = 'Button FollowButton Module UserFollowButton btn gridItem hasText notNavigatable rounded:not(.dim)';
function click(sel, n){
e=document.createEvent('HTMLEvents');
e.initEvent('click',true,true);
bs=document.querySelectorAll(sel)[0].dispatchEvent(e);
console.log(n);
window.scroll(0,n*move);
}