If a user uses a context menu or browser shortcut to open in a new tab/window (middle click, right click, etc), the leaving page is completely skipped because .click() is never triggered.
There are various ways that this could be accomplished. I fiddled with some javascript options and none of them seemed to work cleanly in the browsers that I tested. Another way would be to rewrite external URLS when parsing the page, so that they will be redirected to the now-leaving page regardless of the click method. This method would cause problems with the way that cookies are used to pass the data.
I've added a patch that adds a new configuration option for rewriting URLs, this could probably be done better in some areas but I did not want to refactor a ton of code.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | extlink_extra-url-rewrite-git.patch | 7.22 KB | lunitin |
| extlink_extra-url-rewrite.patch | 4.28 KB | lunitin |
Comments
Comment #2
lunitin commentedComment #3
lunitin commentedI guess the way I created this patch was incorrect and it does not cleanly apply to the 7.x-1.x branch in git. I've attached an updated version.
Comment #4
nileshlohar commentedsetting correct status