Skip to content

Instantly share code, notes, and snippets.

@sethwebster
Created November 30, 2013 13:26
Show Gist options
  • Save sethwebster/7719079 to your computer and use it in GitHub Desktop.
Save sethwebster/7719079 to your computer and use it in GitHub Desktop.
For Facebook Pages only, invite all friends to like page. At the time of this writing, this works. Facebook changes things up pretty frequently so YMMV. First, add this code as bookmarklet, then, when inviting friends, scroll to the bottom of your list to ensure they're all loaded. Finally, click the bookmarklet. Viola, all friends invited.
javascript:function inviteNext(e,t){if(e<t.length){total++;t[e].click();e++;setTimeout(function(){inviteNext(e,t)},100);updateCount()}else{destroyPopup()}}function updateCount(){var e=document.getElementById("invite-all-count-sw");e.innerText=total+"/"+els.length}function createPopup(){var e=document.getElementsByTagName("head")[0];var t=document.getElementsByTagName("body")[0];var n=document.createElement("div");n.setAttribute("id","add-all-div-sw");n.setAttribute("style",'text-align:center;font-family:"lucida grande",tahoma,verdana,arial,sans-serif;padding:20px;width:25%;height;20%;border:2px solid #ccc;background-color:#fff;position:relative;margin:0 auto 0 auto');n.innerHTML='Inviting Everyone in the List...<span id="invite-all-count-sw">0</span> invited so far...';t.appendChild(n);popup=n}function destroyPopup(){popup.parentElement.removeChild(popup)}var popup=null;var total=0;var els=document.getElementsByClassName("uiButton _1sm");createPopup();inviteNext(0,els)
@Shurshik
Copy link

It can be useful for you: there is an extension that automatically invites people who liked your post - to like your page: https://www.youtube.com/watch?v=ILgrsfB9bwc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment