Created
August 17, 2015 12:20
-
-
Save leotm/e55371b97e8eded5d186 to your computer and use it in GitHub Desktop.
Instagram - Friend or Follow - Bulk Unfollow/Follow
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
// So I wrote this purely to reverse getting hacked | |
// Resulting in following an extra 800 random people | |
// Always de-activate third-party tools after API authorisation! | |
// Enter into your browser console | |
var items = document.querySelectorAll("#content > div > img"); | |
for (var i = 0; i < items.length; i++) { | |
// Simulates mouse hover over user images to open tooltips | |
// (Prevously tried amending the results classes and attributes) | |
$(items[i]).mouseenter(); | |
} | |
// Wait several minutes until all user tooltips opened | |
// Once complete, this should equal number of user thumbnails you see in the grid gallery | |
document.querySelectorAll(".button-unfollow").length; | |
// To follow, change selector to ".button-follow" | |
var buttons = document.querySelectorAll(".button-unfollow"); | |
for (var i = 0; i < buttons.length; i++) { | |
// Simulates Unfollow button click on all users | |
buttons[i].click(); | |
} | |
// Now you should see your number of unfollowers/followers updating live |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
doesnt wotk