User:Bobogoobo/common.js: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(for styling purposes) |
||
(2 intermediate revisions by the same user not shown) | |||
Line 8: | Line 8: | ||
'</li>' | '</li>' | ||
); | ); | ||
//Add Purge to "More" box | |||
if (mw.config.get('wgArticleId') && mw.config.get('wgNamespaceNumber') !== '-1') { | |||
$('#p-cactions .vector-menu-content-list').append( | |||
'<li id="ca-purge" class="mw-list-item">' + | |||
'<a href="?action=purge"><span>Purge</span></a>' + | |||
'</li>' | |||
); | |||
} | |||
}); | }); |
Latest revision as of 11:58, 26 June 2023
$(function() {
//Add PrefixIndex to toolbox
$('#p-tb li:nth-of-type(2)').after(
'<li id="t-prefixindex">' +
'<a href="/view/Special:PrefixIndex?prefix=&namespace=' +
mw.config.get('wgNamespaceNumber') +
'">Prefix Index</a>' +
'</li>'
);
//Add Purge to "More" box
if (mw.config.get('wgArticleId') && mw.config.get('wgNamespaceNumber') !== '-1') {
$('#p-cactions .vector-menu-content-list').append(
'<li id="ca-purge" class="mw-list-item">' +
'<a href="?action=purge"><span>Purge</span></a>' +
'</li>'
);
}
});