I'm looking for an extension capable of opening multiple hyperlinks at once in tabs.

I don't want to configure Safari to open in tabs any hyperlink clicked.
I wan't to select one or multiple hyperlinks and open all the pages at once.

Same behavior as: https://addons.mozilla.org/en-US/firefox/addon/multi-links/

Thx!

link|improve this question
feedback

1 Answer

Try this out as a bookmarklet:

javascript:(function(){var n_to_open,dl,dll,i; function linkIsSafe(u) { if (u.substr(0,7)=='mailto:') return false; if (u.substr(0,11)=='javascript:') return false; return true; } n_to_open = 0; dl = document.links; dll = dl.length; if (window.getSelection && window.getSelection().containsNode) { /* mozilla */ for(i=0; i<dll; ++i) { if (window.getSelection().containsNode(dl[i], true) && linkIsSafe(dl[i].href)) ++n_to_open; } if (n_to_open && confirm('Open ' + n_to_open + ' selected links in new windows?')) { for(i=0; i<dll; ++i) if (window.getSelection().containsNode(dl[i], true) && linkIsSafe(dl[i].href)) window.open(dl[i].href); } } /* /mozilla */ if (!n_to_open) { /*ie, or mozilla with no links selected: this section matches open_all_links, except for the alert text */ for(i = 0; i < dll; ++i) { if (linkIsSafe(dl[i].href)) ++n_to_open; } if (!n_to_open) alert ('no links'); else { if (confirm('No links selected. Open ' + n_to_open + ' links in new windows?')) for (i = 0; i < dll; ++i) if (linkIsSafe(dl[i].href)) window.open(dl[i].href); } } })();
link|improve this answer
Could you explain what this does, or where you got the code from? – sblair Apr 9 at 4:50
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.