User:Jmcgnh/common.js
Appearance
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes. A guide to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the appropriate village pump. This code will be executed when previewing this page. |
![]() | The accompanying .css page for this skin is at User:Jmcgnh/common.css. |
// 2017-08-16 alternate hostname for dispenser tools: toolserver.org
// The entries here have been gathered from a number of different sources, best sought by looking for the tool name
// Because there seemed to be an unwanted interaction with page curation tools, I placed all of the addPortletLink calls
// inside the scope of the when-ready-done block originally provided for Lourdes/PageCuration.js
// This version was tested as working on 2017-08-29
$.when( mw.loader.using( ['mediawiki.util'] ), $.ready ).done( function() {
// add to toolbox instead of menubar // Linkback: [[User:Lourdes/PageCuration.js]]
mw.util.addPortletLink(
'p-tb',
mw.util.getUrl('Special:NewPagesFeed'),
'Page Curation',
'pt-pagecuration',
'View Special:New Pages using the Page Curation tool',
null,
'#pt-preferences'
);
mw.util.addPortletLink ('p-tb', wgServer+wgArticlePath.replace("$1", "Special:PrefixIndex/"+wgPageName+"/"), 'Subpages');
mw.util.addPortletLink ('p-tb', wgServer+wgArticlePath.replace("$1", "Special:WhatLinksHere/"+wgPageName+"?namespace=0"), 'Links from articlespace');
mw.loader.load( "https://meta.wikimedia.org/w/index.php?title=User:Zhaofeng_Li/Reflinks.js&action=raw&ctype=text/javascript" );
mw.util.addPortletLink ('p-tb', "http://toolserver.org/~dispenser/cgi-bin/dab_solver.py/" + mw.config.get('wgPageName'), 'Dab solver');
mw.util.addPortletLink ('p-tb', "http://toolserver.org/~dispenser/cgi-bin/dablinks.py?page=" + mw.config.get('wgPageName'), 'Dablinks');
mw.util.addPortletLink ('p-tb', "https://tools.wmflabs.org/dplbot/dab_fix_list.php?title=" + mw.config.get('wgPageName'), 'Dab fix list');
mw.util.addPortletLink ('p-tb', "http://toolserver.org/~dispenser/cgi-bin/webchecklinks.py?page=" + mw.config.get('wgPageName'), 'Checklinks');
mw.util.addPortletLink ('p-tb', "http://sumsearch.org/cite/", 'Cite maker1');
mw.util.addPortletLink(
"p-tb",
"https://tools.wmflabs.org/copyvios/?lang=" + mw.config.get("wgContentLanguage") + "&project=" + mw.config.get("wgSiteName").toLowerCase() + "&title=" + encodeURIComponent(mw.config.get("wgPageName")),
"Copyvio check",
"t-copyvio-check",
"Check this page for copyright violations"
);
});
importScript( 'User:Jcgoble3/SectionInput.js' ); // Backlink: [[User:Jcgoble3/SectionInput.js]]
importScript('User:Frietjes/findargdups.js'); // Linkback: [[User:Frietjes/findargdups]]
importScript('User:Jmcgnh/hidetopcontribs.js'); // Linkback: [[User:Jmcgnh/hidetopcontribs.js]] w/ attribution to [[User:Sparkla/hidetopcontribs.js]]
// Link classifier - don't need it to run all the tinme
LinkClassifierOnDemand=true; // would like it to normally be "true", but can't get that to work yet
importScript('User:Jmcgnh/linkclassifier-list-self-redirects.js'); // Linkback: [[User:Anomie/linkclassifier.js]]
importStylesheet('User:Anomie/linkclassifier.css'); // Linkback: [[User:Anomie/linkclassifier.css]]
$.when( mw.loader.using( 'mediawiki.util' ), $.ready ).then( function() {
var el = mw.util.addPortletLink('p-tb', '', 'Link Classifier');
$(el).click(function() {
LinkClassifier.onDemand();
} );
} );