Ce site disposera de fonctionnalités limitées pendant que nous effectuons des opérations de maintenance en vue de vous proposer un meilleur service. Si un article ne règle pas votre problème et que vous souhaitez poser une question, notre communauté d’assistance est prête à vous répondre via @FirefoxSupport sur Twitter, et /r/firefox sur Reddit.

Rechercher dans l’assistance

Évitez les escroqueries à l’assistance. Nous ne vous demanderons jamais d’appeler ou d’envoyer un SMS à un numéro de téléphone ou de partager des informations personnelles. Veuillez signaler toute activité suspecte en utilisant l’option « Signaler un abus ».

En savoir plus

Middle click on link not opening in new tab

  • 7 réponses
  • 4 ont ce problème
  • 14 vues
  • Dernière réponse par cor-el

more options

Normally, middle clicking on a link will open the link in a new tab - that's what I want it to do. But some days middle clicking on a link will act like left clicking on a link, opening the page in THIS tab instead of a new one (leaving the page I was on). Anywhere else in the OS middle click is acting normally; it's a firefox problem.

Normally, middle clicking on a link will open the link in a new tab - that's what I want it to do. But some days middle clicking on a link will act like left clicking on a link, opening the page in THIS tab instead of a new one (leaving the page I was on). Anywhere else in the OS middle click is acting normally; it's a firefox problem.

Toutes les réponses (7)

more options

Enter about:config in the address bar. In the search panel enter "click" w/o quotes. Make sure browser.tabs.opentabfor.middleclick is set to true.

more options

Start Firefox in Safe Mode to check if one of the extensions ("3-bar" menu button or Tools -> Add-ons -> Extensions) or if hardware acceleration is causing the problem.

  • Switch to the DEFAULT theme: "3-bar" menu button or Tools -> Add-ons -> Appearance
  • Do NOT click the "Refresh Firefox" button on the Safe Mode start window

It is possible that there is JavaScript onclick is involved in the link that overrides this behavior.

Does this happen randomly or can you reproduce this on specific web pages?

more options

I found out that I can reproduce it on specific web pages. Middle click on any of the word rectangles here: http://www.thesaurus.com/browse/bug?s=t (but other links like in the menu etc do not have the problem)

Also, on that page right clicking on links acts like left click too! (But I know I have seen pages where middle click acts like left click and right click acts properly - I know because I was right clicking and choosing open in new tab)

Feels like a bug in firefox because I see nothing odd about the html for those links.

more options

All those links have a JavaScript onclick event listener attached that intercepts all mouse click and opens the link in the current tab.

more options

What in that code indicates to you that the links have javascript onclick event listeners attached to them? (I would like to learn how to spot it)

I wonder if there is an addon to force proper behaviour

more options

soundwave said

What in that code indicates to you that the links have javascript onclick event listeners attached to them? (I would like to learn how to spot it) Right-click an empty spot on the page and choose View Page Source. Do CTRL+F and search for onclick. I wonder if there is an addon to force proper behaviour

The Web Developer extension's toolbar has a Disable button where you can easily disable/enable Javascript.

more options

The 'ev' button that you see in the screenshot at the end of a line shows that an onclick handler is attached.