Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // http://www.hqoboi.com/eng/links_sitemap.html
- for(var i=0,b=[],ul=document.links;i<ul.length;i++)(/eng/.test(ul[i].href) && (setTimeout(get_url,i*100,ul[i].href,parse1)))
- function parse1(){
- var a=unique1(this.toString().match(/\w+\/\w+.jpg/gim).map(function(v,i){return 'http://www.hqoboi.com/img/' + v.replace("_/","/")})).sort();
- console.log(a.join("\n"),a.length);
- post_imgur(a,print1);
- }
- function print1(){console.log(this.toString().split("\n").length-1)}
- function unique1(a){for(var c=Object.create(null),d=[],b=a.length;b--;)c[a[b]]||(c[a[b]]=!0,d.push(a[b]));return d};
- function post_imgur(a,callback) {
- var r=new XMLHttpRequest();
- r.open("POST","http://176.34.162.148/jabry/imgur1.asp?u=&b=",true);
- //r.open("POST","http://notebook1.lan:8000/jabry/imgur1.asp?u=&b=",true);
- r.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
- r.onreadystatechange=function(){if (this.readyState==4 && this.status==200) callback&&callback.call(this.responseText); }
- r.send("u=" + a.join(","));
- }
- function get_url(url,callback) {
- var r=new XMLHttpRequest();
- r.open("GET",url,true);
- //r.setRequestHeader("X-Requested-With", "XMLHttpRequest");
- //r.setRequestHeader("Accept-Encoding", "gzip");
- r.onreadystatechange=function(){
- if (this.readyState==4 && this.status==200 && callback) callback.call(this.responseText);
- }
- r.send();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement