User:Significa liberdade/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 can be added at User:Significa liberdade/common.css. |
/*Rater*/ mw.loader.load( '/w/index.php?title=User:Evad37/rater.js&action=raw&ctype=text/javascript' ); // Backlink: [[User:Evad37/rater.js]]
/* PageCuration for NPP and AfC */ importScript('User:Schminnte/PageCuration.js'); // Linkback: [[User:Schminnte/PageCuration.js]]
/*Copyvio*/ mw.loader.using('mediawiki.util', function() {
if (mw.config.get('wgNamespaceNumber') < 0) {
return;
}
var url = 'https://copyvios.toolforge.org/?lang=' + mw.config.get('wgContentLanguage') +
'&project=' + mw.config.get('wgSiteName').toLowerCase() +
'&title=' + encodeURIComponent(mw.config.get('wgPageName'));
if (mw.config.get('wgRevisionId') !== mw.config.get('wgCurRevisionId') ||
mw.util.getParamValue('oldid') !== null) {
url += '&oldid=' + encodeURIComponent(mw.config.get('wgRevisionId'));
}
mw.util.addPortletLink(
'p-tb',
url,
'Copyvio check',
't-copyvio-check',
'Check this page for copyright violations'
);
});
/* AfC */
/*Uploaded from https://github.com/WPAFC/afch-rewrite, commit: 24800715ad8fef3129b80f299ccef602518561b8 (master) */
//<nowiki>
( function () {
// Check that we're in the right namespace and on the right page
switch ( mw.config.get( 'wgNamespaceNumber' ) ) {
case 4: // Wikipedia
case 5: // Wikipedia talk
var pageName = mw.config.get( 'wgTitle' );
// return nothing for now, all drafts are now under Draft namespace
// currently only the article submission script is running here.
// to be used when script(s) for other modules such as category and
// redirect requests are reintergrated into here.
if ( pageName !== 'Articles for creation/sandbox' ) {
return;
}
break;
case 2: // User
case 118: // Draft
break;
default:
return;
}
// Initialize the AFCH object
window.AFCH = {};
// Set up constants
AFCH.consts = {};
AFCH.consts.scriptpath = mw.config.get( 'wgServer' ) + mw.config.get( 'wgScript' );
// These next two statements (setting beta and baseurl) may be modified
// by the uploading script! If you change them, check that the uploading
// script at scripts/upload.py doesn't break.
AFCH.consts.beta = false;
AFCH.consts.baseurl = AFCH.consts.scriptpath +
'?action=raw&ctype=text/javascript&title=MediaWiki:Gadget-afchelper.js';
$.getScript( AFCH.consts.baseurl + '/core.js' ).done( function () {
var loaded = AFCH.load( 'submissions' ); // perhaps eventually there will be more modules besides just 'submissions'
if ( !loaded ) {
mw.notify( 'AFCH could not be loaded: ' + ( AFCH.error || 'unknown error' ),
{ title: 'AFCH error' } );
}
} );
}() );
//</nowiki>
/*Draftify*/importScript( 'User:MPGuy2824/MoveToDraft.js' ); // Backlink: [[User:MPGuy2824/MoveToDraft.js]]
/*Superlinks is a Wikipedia user script designed to allow powerusers to quickly view pages and information related to the page they are currently viewing*/ importScript( 'User:Bradv/Scripts/Superlinks.js' ); // Backlink: [[User:Bradv/Scripts/Superlinks.js]]
/*CV RevDel*/ importScript( 'User:Enterprisey/cv-revdel.js' ); // Backlink: [[User:Enterprisey/cv-revdel.js]]
/*Capricorn for redirects*/mw.loader.load('//en.wikipedia.org/w/index.php?title=User:Wugapodes/Capricorn.js&action=raw&ctype=text/javascript');
/*Stub sorter*/importScript('User:SD0001/StubSorter.js'); // [[User:SD0001/StubSorter.js]]
/*ReFill*/mw.loader.load( "https://meta.wikimedia.org/w/index.php?title=User:Zhaofeng_Li/Reflinks.js&action=raw&ctype=text/javascript" );
/* This script adds a "Page views" link under "Tools" in the sidebar.
The link goes to the external tool https://pageviews.toolforge.org.
On disambiguation pages the script also adds a "Mass views" link to
page views for all pages linked on the page.
To use the script, add the following line to Special:MyPage/common.js:
importScript('User:PrimeHunter/Pageviews.js'); // Linkback: [[User:PrimeHunter/Pageviews.js]]
*/
mw.loader.using(['mediawiki.util'], function () {
mw.util.addPortletLink(
'p-tb',
'https://pageviews.wmcloud.org/?project=en.wikipedia.org&pages=' +
encodeURIComponent(mw.config.get( 'wgPageName' )),
'Page views',
'pt-pageviews',
'Show page views for this page',
null,
'#t-info'
);
if ( document.getElementById( 'disambigbox' ) ) {
mw.util.addPortletLink(
'p-tb',
'https://pageviews.wmcloud.org/massviews/?source=wikilinks&' +
'target=https://en.wikipedia.org/wiki/' +
encodeURIComponent(mw.config.get( 'wgPageName' )),
'Massviews',
'pt-massviews',
'Show page views for pages linked on this disambiguation page',
null,
'#t-info'
);
}
});
/*/DYK Check/*/importScript('User:Shubinator/DYKcheck.js'); //DYKcheck tool
/*/MOSNUM date updates /*/
importScript('User:Ohconfucius/script/MOSNUM dates.js'); // [[User:Ohconfucius/script/MOSNUM dates.js]]