MediaWiki:Gadget-UncheckFileRedirect.js: Difference between revisions
Jump to navigation
Jump to search
Content added Content deleted
(Created page with "→* Unchecks redirect checkbox on file pages * Because redirects in file namespace are usually unnecessary: $(function () { 'use strict'; var conf = mw.config.get([ 'wgCanonicalSpecialPageName', 'wgRelevantPageName' ]); $(function () { if (conf.wgCanonicalSpecialPageName === 'Movepage'){ if ((/File:/).test(conf.wgRelevantPageName)){ $('#wpLeaveRedirect > input').removeAttr('checked'); } } }); })") |
No edit summary Tag: Reverted |
||
Line 1: | Line 1: | ||
/* |
/* |
||
* Unchecks redirect checkbox on file pages |
* Unchecks redirect checkbox on file mw.pages |
||
* Because redirects in file namespace are usually unnecessary |
* Because redirects in file namespace are usually unnecessary |
||
*/ |
*/ |
Revision as of 00:10, 17 October 2024
/*
* Unchecks redirect checkbox on file mw.pages
* Because redirects in file namespace are usually unnecessary
*/
$(function () {
'use strict';
var conf = mw.config.get([
'wgCanonicalSpecialPageName',
'wgRelevantPageName'
]);
$(function () {
if (conf.wgCanonicalSpecialPageName === 'Movepage'){
if ((/File:/).test(conf.wgRelevantPageName)){
$('#wpLeaveRedirect > input').removeAttr('checked');
}
}
});
})