Advertisement
Guest User

Untitled

a guest
Aug 23rd, 2019
585
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. javascript:(function(){
  2. output='<html><head><title>SEO SERP Extraction Tool</title><style type=\'text/css\'>body,table{font-family:Tahoma,Verdana,Segoe,sans-serif;font-size:11px;color:#000}h1,h2,th{color:#405850}th{text-align:left}h2{font-size:11px;margin-bottom:3px}</style></head><body>';
  3. output+='<table><tbody><tr><td><a%20href=\'http://www.chrisains.com\'><img%20src=\'http://www.chrisains.com/wp-content/uploads/2015/06/chrisains.com-logo1.png\'></a></td><td><h1>SEO%20SERP%20Extraction%20Tool</h1></td></tr></tbody></table>';
  4.  
  5. pageAnchors=document.getElementsByTagName('a');
  6. divClasses=document.getElementsByTagName('div');
  7.  
  8. var%20linkcount=0;
  9. var%20linkLocation='';
  10. var%20linkAnchorText='';
  11.  
  12. output+='<table><th>ID</th><th>Link</th><th>Anchor</th>';
  13.  
  14. for(i=0;i<pageAnchors.length;i++){
  15. if(pageAnchors[i].parentNode.getAttribute('class')!='_Rm bc'){
  16. var%20anchorText%20=%20pageAnchors[i].textContent;
  17. var%20anchorLink%20=%20pageAnchors[i].href;
  18. var%20linkAnchor%20=%20anchorLink%20+%20'\t'+anchorText;
  19. var%20anchorID%20=%20pageAnchors[i].id;
  20.  
  21. if(anchorLink!=''){
  22. if(anchorLink.match(/^((?!google\.|cache|blogger.com|\.yahoo\.|youtube\.com\/\?gl=|youtube\.com\/results|javascript:|api\.technorati\.com|botw\.org\/search|del\.icio\.us\/url\/check|digg\.com\/search|search\.twitter\.com\/search|search\.yahoo\.com\/search|siteanalytics\.compete\.com|tools\.seobook\.com\/general\/keyword\/suggestions|web\.archive\.org\/web\/|whois\.domaintools\.com|www\.alexa\.com\/data\/details\/main|www\.bloglines\.com\/search|www\.majesticseo\.com\/search\.php|www\.semrush\.com\/info\/|www\.semrush\.com\/search\.php|www\.stumbleupon\.com\/url|wikipedia.org\/wiki\/Special:Search).)*$/i)){
  23. if(anchorID.match(/^((?!hdtb_more|hdtb_tls|uh_hl).)*$/i)){linkLocation+=anchorLink+'<br%20/>';
  24. linkAnchorText+=anchorText+'<br%20/>';
  25. linkcount++;
  26.  
  27. if%20(anchorText%20===%20undefined)%20anchorText%20=%20pageAnchors[i].innerText;
  28. output+='<tr>';
  29. output+='<td>'+linkcount+'</td>';
  30. output+='<td>'+pageAnchors[i].href+'</a></td>';
  31. output+='<td>'+anchorText+'</td>';
  32. output+='</tr>\n';
  33. }}}}}
  34.  
  35. output+='</table><br/><h2>URL%20List</h2><div>';
  36. output+=linkLocation;
  37. output+='</div><br/><h2>Anchor%20Text%20List</h2><div>';
  38. output+=linkAnchorText;
  39. output+='<br/>%C2%A0<br/><p%20align=center><a%20href=\'http://www.chrisains.com\'>www.chrisains.com</a></p>';
  40.  
  41. with(window.open()){document.write(output);
  42.  
  43. document.close();
  44. }
  45. })();
Advertisement
RAW Paste Data Copied
Advertisement