1

Firefox 38.0.5 @ OSX 10.10.3.

I've noticed that with some links, Firefox will switch to the newly opened tab, regardless of its settings.

"When I open a link in a new tab, switch to it immediately" is off, "browser.tabs.loadBookmarksInBackground" is on.

  • only happens if I CMD+left click, while if I middle click it works as expected
  • occurs with a mailing list I receive, but if I copy the same html code of that mail in a clean html page, it doesn't happen any more
  • didn't happen with Chrome
  • those links have an image as content, and no text
  • I access them through google inbox or gmail

How do I make it work properly even with CMD+left click?

0

From: Why does CTRL-click not open some links in a new tab?

This applies to CMD + Click as well, despite just stating Ctrl + Click.

Lets take this link as an example:

<a href="test.php" onclick="someFunction(this); return false;">Test</a>

The href attribute, in this case, is creating a pseudo link for readability (it will also allow the link to work even if JavaScript is disabled). The reason for this is because the onclick attribute always runs first. Big sites like Google do this to track clicks and to try to prevent a user from visiting malware sites. Because of this, for some reason Ctrl + Click does not work. However, if you use the middle-button on your mouse, that almost always works.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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