Extra caution is recommended when installing recently uploaded/updated scripts (read more)
Be sure you trust any scripts you install
window.open Opens in New Tab
Causes URIs opened with window.open to instead open in a new tab.
Does what the summary says, with one short line of code. Unfortunately, it uses unsafeWindow. I tried the alternative methods listed here: http://wiki.greasespot.net/UnsafeWindow , but they didn't work. I don't see how my use could be dangerous, though.
EDIT: Descriptor has kindly shown a way to do this with the browser. about:config > browser.link.open_newwindow = 3 > browser.link.open_newwindow.restriction = 0. I haven't tested this yet, so I'll leave the script (and this comment) here for now.
EDIT: The built-in way works great, but I'll leave the script up for those who don't know of the preferences.
|
|
true... but the about:config is not quite good enough...
browser.link.open_newwindow.restriction Possible values and their effects
Divert all links according to browser.link.open_newwindow. (Default in Firefox 1.0.x and SeaMonkey) This includes: * All HTML links with target="_blank".
[edit]
Do not divert any links (browser.link.open_newwindow will have no effect).
Divert all links according to browser.link.open_newwindow, unless the new window specifies how it should be displayed. (Default in Firefox 1.5 and later and Camino 1.5) This includes: * All links with target="_blank".
This does not include: * JavaScript calls to window.open() <u>with the "features" parameter</u> (3rd parameter). what I REALLY need to know is how to get Those js windows to open in tabs...
'javascript'
|
|
|
It's built into the browser already...
See also this thread. |
|
|
Sweeet one liner. I love one liners! |
|
|
I don't know why nobody thought of this before! It's incredibly useful, and it's just one line of code. You can't get much more elegant than that :) 10 / 10, definitely. |
You could comment on this script if you were logged in.
