Bookmarklets are scripts that can be added to and ran from your Bookmark (Favorite) to enrich the web browsing environment.
These are examples of Bookmarklets that I wrote. They work on Internet Explorer.
javascript:with(document){
if(onmousewheel){void(onmousewheel=null)}
else{
void(onmousewheel=function(k,o){
k=event.wheelDelta/-120;
o=selection.createRange();
if(o.text){
o.moveStart('word',k);
o.moveEnd('word',k);
o.select();
event.returnValue=false;
}
else{event.returnValue=true}});
void(ondblclick=function(){onmousewheel=null});
}
}
javascript:(function(i){with(document){
for(i_in_links){
void(links[i].ondragstart = function(f,s,a,b,X,Y){
f = createElement('iframe');
f.src = this.href;
body.appendChild(f);
s = f.style;
s.position = 'absolute';
with(event){
a = clientX;
b = clientY + body.scrollTop;
this.ondrag = function(){
X = clientX;
Y = clientY + body.scrollTop;
s.pixelLeft = a < X ? a : X;
s.pixelWidth = a < X ? X - a : a - X;
s.pixelTop = b < Y ? b : Y;
s.pixelHeight = b < Y ? Y - b : b - Y
};
}
this.onclick = function(){
body.removeChild(f);
this.onclick = null;
return_false;
}
})
}
}})()
javascript:(function(n,i,e){
if(n.id && n.tagName.match(/h[1-6]|div|dt/i)){
e = document.createElement('a');
e.href = '#' + n.id;
e.appendChild(document.createTextNode(' '));
n.insertAdjacentElement('afterBegin',e);
}
for(i in n.childNodes){
arguments.callee(n.childNodes[i]);
}
})(document.body)
javascript:(function(a, X, Y, n){with(document){
a = new_Array();
X = new_Array();
Y = new_Array();
n = 0;
onmousemove = function(e, b, s){
with(event){
if(n++ % 8 > 0) return;
e = elementFromPoint(clientX, clientY);
b = false;
if(!e.tagName.match(/body|div|table/i) && a.length < 32){
for(i = 0; i < a.length; i++){
if(a[i] == e) b = true;
}
if(!b) a.push(e);
}
X.push(clientX);
Y.push(clientY);
if(X.length > a.length){
X.shift();
Y.shift();
}
for(i = 0; i < a.length; i++){
s = a[i].style;
s.position = 'absolute';
s.pixelLeft = X[i];
s.pixelTop = Y[i];
}
}
}
}})()
javascript:(function(i){with(document){
for(i_in_document.links){
links[i].onmouseout = function(){
this.click();
}
}
}})()javascript:(function(f,s){
f = function(n, v){
document.cookie = n + '=' + escape(v)
+ ';_expires=Fri,_01-Jan-2030_00:00:00_GMT';
};
s = document.selection.createRange().text;
if(s){
f('bookmarkletmarker' + document.location, s);
}
else{
alert('Nothing_was_selected.');
}
})()javascript:(function(f, s, r){
f = function(n, i, cs, c){
cs = document.cookie.split("; ");
for (i=0; i < cs.length; i++){
c = cs[i].split("=");
if(n == c[0]) return_unescape(c[1]);
}
return_null;
};
s = f('bookmarkletmarker' + document.location);
if(s){
r = document.selection.createRange();
r.findText(s);
r.select();
}
})()javascript:(function(l, i, n, a, f){with(document){
f = function(q, o, c, t){
if(!q.getAttribute) return;
c = q.getAttribute('cite');
t = q.getAttribute('title');
o = createElement('a');
o.href = c;
t = '(in_' + (t ? t : c) + ')';
o.appendChild(createTextNode(t));
return_ c ? o : null;
};
l = body.getElementsByTagName('blockquote');
for(i_in_l){
n = l[i];
a = f(n);
if(a) n.appendChild(a);
}
l = body.getElementsByTagName('q');
for(i_in_l){
n = l[i];
a = f(n);
if(a) n.parentNode.insertBefore(a, n);
}
}})()These programs work on Windows with Internet Explorer 5.0 or later.