I am making a javascript bookmarklet that resizes all images, periodically.
javascript: function x(){
for(i=0;i<=document.getElementsByTagName('img').length;i++)
document.getElementsByTagName('img')[i].width+=1;
};
t = window.setTimeout("x()",100);
void(0);
But it runs only once. What is the problem here??
Are you looking for setInterval()
instead of setTimeout()
by any chance?
t = window.setInterval("x()",100);