Advertisement
Guest User

Untitled

a guest
Oct 25th, 2011
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.56 KB | None | 0 0
  1. // ==UserScript==
  2. // @name EnableGoogleWebHistory
  3. // @author mallowlabs
  4. // @namespace http://mallowlabs.s206.xrea.com/
  5. // @version 0.0.2
  6. // @license public domain
  7. // @description : Enable Google Web History
  8. // @published 2007-01-05
  9. // @modified 2006-01-05
  10. // @include *
  11. // ==/UserScript==
  12. // see also
  13. // http://www.scss.com.au/family/andrew/opera/panels/pagerank/
  14. // http://d.hatena.ne.jp/amatanoyo/20080104/1199450996
  15. // =========================================
  16. (function(){
  17. // avoid frame
  18. if (window.self != window.parent) return;
  19. var r=function(x,y){
  20. return Math.floor((x/y-Math.floor(x/y))*y+.1);
  21. },
  22. ch=function(url){
  23. url='info:'+url;
  24. var c=[0x9E3779B9,0x9E3779B9,0xE6359A60],i,j,k=0,l,f=Math.floor,
  25. m=function(c){
  26. var i,j,s=[13,8,13,12,16,5,3,10,15];
  27. for(i=0;i<9;i+=1){
  28. j=c[r(i+2,3)];
  29. c[r(i,3)]=(c[r(i,3)]-c[r(i+1,3)]-j)^(r(i,3)==1?j<<s[i]:j>>>s[i]);
  30. }
  31. };
  32. for(l=url.length;l>=12;l-=12){
  33. for(i=0;i<16;i+=1){
  34. j=k+i;c[f(i/4)]+=url.charCodeAt(j)<<(r(j,4)*8);
  35. }
  36. m(c);
  37. k+=12;
  38. }
  39. c[2]+=url.length;
  40. for(i=l;i>0;i--)
  41. c[f((i-1)/4)]+=url.charCodeAt(k+i-1)<<(r(i-1,4)+(i>8?1:0))*8;
  42. m(c);
  43. return'6'+c[2];
  44. };
  45. var url=document.location;
  46. /* create image element */
  47. new Image().src = 'http://www.google.com/search?client=navclient-auto&ch='+ch(url)+'&features=Rank&q=info:'+escape(url);
  48. })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement