In Google search results, in Firefox or Chrome, I get URLs that go through Google and not directly to the target site. For example, at
http://www.google.com/search?q=foo
the first result is
I don't really care that Google is tracking what I click, and I don't really care about the extra indirection when I click on a result (though both are concerns). But I find it annoying that I can't copy-paste a result by simply right-clicking on a link and choosing “copy link address” (I want to get the real result, not Google's redirection to it).
I want to have the direct URL http://en.wikipedia.org/wiki/Foobar, at least for copy-paste purposes, in Firefox and Chrome.
Google's behavior changed several times:
- When I asked this question, in a browser without Javascript, you got direct URLs in results: http://en.wikipedia.org/wiki/Foobar. The indirection was added via Javascript.
- Some time later, Google changed to provide indirect results in all browsers.
Since 2012-09-04, it seems that:
- In a browser without JS, the HTML still contains indirect results.
- In a browser with JS support (at least in recent Firefox and Chrome), the HTML contains a direct result in the
href
attribute, but there is anonmousedown
attribute that invokes therwt
function which does rewrite the link. You see the direct link when you hover, but you get an indirect link like the one above when you click or copy-paste.
mousedown
event and only change the link to the redirect ifevent.button !== 2
(2 is right click).