User:Bhairava7/DiscussionCloser.js: Difference between revisions
From Test Wiki
Content deleted Content added
m Aviram7 moved page MediaWiki:Gadget-DiscussionCloser.js to User:Aviram7/DiscussionCloser.js without leaving a redirect: revert |
m Bhairava7 moved page User:Kiteretsu/DiscussionCloser.js to User:Bhairava7/DiscussionCloser.js without leaving a redirect |
||
| (5 intermediate revisions by 2 users not shown) | |||
| Line 5: | Line 5: | ||
//Maintained by DannyS712 |
//Maintained by DannyS712 |
||
var DiscussionCloser_config = { |
var DiscussionCloser_config = { |
||
name: '[[User: |
name: '[[User:Kiteretsu/DiscussionCloser|DiscussionCloser]]', |
||
version: '1.7.4', |
version: '1.7.4', |
||
debug: false |
debug: false |
||
| Line 61: | Line 61: | ||
if ((($('#ca-addsection').length > 0) || |
if ((($('#ca-addsection').length > 0) || |
||
(mw.config.get('wgPageName') == 'Test Wiki:Community portal') || |
(mw.config.get('wgPageName') == 'Test Wiki:Community portal') || |
||
(mw.config.get('wgPageName') == 'Test Wiki: |
(mw.config.get('wgPageName') == 'Test Wiki:Request for permissions')) && |
||
(mw.config.get('wgAction') == 'view')) { |
(mw.config.get('wgAction') == 'view')) { |
||
dc_run(); |
dc_run(); |
||
| Line 284: | Line 284: | ||
$('#DC-close').click(function() { |
$('#DC-close').click(function() { |
||
$('#DC-modal').remove(); |
$('#DC-modal').remove(); |
||
window.location.href = 'https:// |
window.location.href = 'https://testwiki. wiki/wiki/'+mw.config.get('wgPageName')+'#'+sectiontitle2; |
||
window.location.reload(); |
window.location.reload(); |
||
}); |
}); |
||
| Line 297: | Line 297: | ||
} |
} |
||
mw.loader.using(['mediawiki.util', 'mediawiki.api', 'mediawiki.Title'], function() { |
mw.loader.using(['mediawiki.util', 'mediawiki.api', 'mediawiki.Title'], function() { |
||
mw.loader.load('//testwiki. wiki/w/index.php?title=User: |
mw.loader.load('//testwiki. wiki/w/index.php?title=User:Kiteretsu/DiscussionCloser.css&action=raw&ctype=text/css', 'text/css'); // Import stylesheet |
||
dc_init(); |
dc_init(); |
||
}); |
}); |
||