Advertisement
rg443

bang -> imgur

Nov 8th, 2013
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var p=location.href,i=0,j=0,h={};
  2. rec1(p);
  3. function rec1(p){
  4. var r=new XMLHttpRequest();
  5. r.open("GET",p);
  6. i++;
  7. //console.log(i,p,j);
  8. r.onload=function(){
  9.    j--
  10.    var fo=(this.response.match(/"[^/]\S+\/(?=">)/gim)||[]).map(function(v){return v.replace("\"",p)});
  11.    var fi=(this.response.match(/"\S+jpg(?=")/gim)||[]).filter(function(v){return !/-\d+x\d+|-thumb/.test(v)}).map(function(v){return p +v.substring(1)});
  12.    fi.length&&post_imgur(fi,function(){});
  13.    fi.length&&(h[p]=fi);
  14.    console.log(i,p,j,fi.length);
  15.  
  16.    fo.forEach(function(v,i){
  17.       if(!h.hasOwnProperty(v)) {
  18.          h[v]="";
  19.          setTimeout(rec1,j*100,v);
  20.          }
  21.       })
  22.    }
  23. r.send();
  24. j++;
  25.  
  26.  
  27. }
  28.  
  29. function post_imgur(a,callback) {        
  30. var r=new XMLHttpRequest();
  31. r.open("POST","http://176.34.162.148/jabry/imgur1.asp?u=&b=&x=",true);
  32. r.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
  33. r.onreadystatechange=function(){if (this.readyState==4 && this.status==200) callback.call(this.responseText); }
  34. r.send("u=" + a.join(","));
  35. }
  36. // http://img1.bangtidy.eu/celebrity_archive/wp-content/uploads/2013/11/07/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement