Difference between revisions of "MediaWiki:Common.js"
From Marathon Documentation
(Created page with "→Any JavaScript here will be loaded for all users on every page load.: function open_in_mmv(href) { var t = $('a.image[href="' + (href || this.href) + '"]'); return t &&...") |
|||
Line 1: | Line 1: | ||
/* Any JavaScript here will be loaded for all users on every page load. */ |
/* Any JavaScript here will be loaded for all users on every page load. */ |
||
− | function open_in_mmv(href) { var t = $('a.image[href="' + (href || this.href) + '"]'); return t && t.length ? |
+ | function open_in_mmv(href) { var t = $('a.image[href="' + (href || this.href) + '"]'); return t && t.length ? t.click() && false : true; } |
Revision as of 11:37, 9 October 2014
/* Any JavaScript here will be loaded for all users on every page load. */ function open_in_mmv(href) { var t = $('a.image[href="' + (href || this.href) + '"]'); return t && t.length ? t.click() && false : true; }