Sunday, August 07, 2005

Bookmarklets, a geek's explanation (part 1)

You may have heard the term before, but I've been using these lil scripts for a while without even knowing anyone else knew what they are.

A bookmarklet is a specially formed javascript that you can set as a bookmark for quick use.

Here are a couple scripts that I use on a regular basis. To use them, simply drag the links too your bookmarks bar.

  • Bloglines: [Sub w/Bloglines]
  • javascript:{   location.href=''+location.href; }p void(1);

  • Technorati: Search based on the current page [Technorati This]
  • javascript:{   w=window;   d=document;   var%20u;   s='';   ds=d.selection;   if(ds&&ds!=u) {     if(ds.createRange()!=u) {       s=ds.createRange().text;     }   }   else if(d.getSelection!=u){     s=d.getSelection()+'';   }   else if(w.getSelection!=u){     s=w.getSelection()+'';   }   if(s.length%3C2){     h=String(w.location.href);     if(h.length==0||h.substring(0,6)=='about:'){       s=prompt('Technorati%20Realtime%20Search%20for:',s);     }     else{       s=w.location.href;     }   }   if(s!=null)     w.location=''+escape(s); } void(1);

  • Blogger/Blogspot: [BlogThis!]
  • javascript:{   Q='';   x=document;   y=window;   if(x.selection){     Q=x.selection.createRange().text;   }   else if(y.getSelection){     Q=y.getSelection();   }   else if(x.getSelection){     Q=x.getSelection();   }   winParams='scrollbars=no,width=475,height=300,top=175,left=75,status=yes,resizable=yes';'     t='+escape(Q)+'&u='+escape(location.href)+     '&n='+escape(document.title),'bloggerForm',winParams); } void(1);

Technorati Tags: , ,


Post a Comment

Links to this post:

Create a Link

<< Home