Title: [Bookmarklet] Open all "new" links (watchlist, unread, new replies, etc) Post by: nimda on January 24, 2013, 01:03:32 AM Meta seemed an appropriate place, as this is "discussion about the Bitcoin Forum," but I'm half-expecting this topic to be moved.
A bookmarklet is a small piece of javascript inside a bookmark. All modern browsers can use them. I made one to open all "new" links on the watchlist page. Coupled with the right browser settings to make pop-ups appear in tabs, (or for Chrome, the One Window extension) it makes reading much easier. Code: var ls = new Array(); Code: javascript:(function(){var%20ls=new%20Array();var%20ln=document.links.length;var%20h;var%20n;for(i=0;i%3Cln;i++){h=document.links[i].href;if(h.indexOf('new')%3E0){ls.push(h);}}if(ls.length%20%3E%2010){n=prompt(%22How%20many%20links%3F%22,10);}else{n=ls.length;}for(i=0;i%3Cn;i++){window.open(ls[i]);}void(0);})(); Title: Re: [Bookmarklet] Open all "new" links (watchlist, unread, new replies, etc) Post by: World on January 24, 2013, 02:04:18 AM useful thank you
Title: Re: [Bookmarklet] Open all "new" links (watchlist, unread, new replies, etc) Post by: nimda on February 25, 2013, 11:05:39 PM Probably should reload the watchlist afterward.
Code: javascript:(function(){var ls=new Array();var ln=document.links.length;var h;var n;for(i=0;i<ln;i++){h=document.links[i].href;if(h.indexOf('new')>0){ls.push(h);}}if(ls.length > 8){n=prompt("How many links%3F",8);}else{n=ls.length;}for(i=0;i<n;i++){window.open(ls[i]);}location.reload();void(0);})(); |