Page 1 of 1

a site "controls" an opened tab (for external links)

Posted: Sat Jul 30, 2011 3:23 pm
by u.o.
What happens at the moment
  1. I visit page A
  2. on page A I click on an external link to page B with left-mouse-button
  3. a new tab opens and page B loads
  4. I switch to the tab with page A and click on another external link (this time to page C)
  5. now no new tab opens, but page C loads in the tab with (former) page B
So, page A, kind of, "controls" the second tab. Page A can load all links into this tab.

Even if I switch to another page A2 (from the same site), all external links are opened in the tab that got opened before by page A.

What I'd like to happen
These external links from page A should load in separate tabs. Page A shouldn't even "know", if there exists a tab it opened.

Examples for "page A"
As far as I understand, this happens with links from inside of Flash and/or with onclick (or something like that) via JavaScript (not using the a element). Of course this happens not with all such links (afaik).

Example for a javascript link: any link container from relink.us (Google search). Some of these containers open a frameset from the same domain ("relink.us/getfile.php"), containing the external link inside a frame. But some containers load the external site directly. The problem exists with both forms.

Example for a Flash link: this slideshare presentation has two links on slide 20. Click on the first, then click on the second. They open in the very same tab.

Re: a site "controls" an opened tab (for external links)

Posted: Sat Jul 30, 2011 3:41 pm
by Giorgio Maone
It happens with any link (plain old HTML ones included) which specify target attribute different than "_blank", "_top", "_parent" or "_self".
If you want to avoid it, just middle-click on the link (of course it won't work with most JavaScript and Flash links, but nothing can be done about it).

Re: a site "controls" an opened tab (for external links)

Posted: Sat Jul 30, 2011 4:09 pm
by u.o.
Oh, I see. Thanks for your explanation.

Yes, I'm used to middle-clicking such links. But, as you mentioned too, this does not work for JavaScript or Flash links :(
Giorgio Maone wrote:but nothing can be done about it
Is this technical not possible? Or would it be possible as an Firefox core about:config feature or as an additional Firefox add-on?

Wouldn't it be "enough", if Firefox would ignore all target attribute values that are different to "_blank", "_top", "_parent" or "_self"? And possibly interpret them like _blank → so all those pages would open in a new tab but never open in an existing tab?
Or: let Firefox "forget" about tabs opened that way and mutate them to "normal", user-controlled opened tabs? Or interpret each link opening a new tab as if it was middle-clicked?

Re: a site "controls" an opened tab (for external links)

Posted: Sat Jul 30, 2011 6:16 pm
by dhouwn
Not entirely related, but for submit buttons there is an extension that enables middle-clicking them like normal links: http://code.kliu.org/misc/tabsubmit/