Documentation may be created at User:Higgs1/common.js/doc.
Note: After saving, you have to bypass your browser's cache to see the changes.
Google Chrome, Firefox, Microsoft Edge, and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button.
For details and instructions about other browsers, see Wikipedia:Bypass your cache.
mw.util.wikiScript = mw.util.wikiScript || function (str) {
return mw.config.get("wgScriptPath") + "/" + (str || "index") + mw.config.get("wgScriptExtension")
}
if ( !$( '#ca-purge' ).length && mw.config.get( 'wgIsArticle' ) ) {
mw.util.addPortletLink(
'p-cactions',
mw.util.wikiScript() + '?' + $.param({ title: mw.config.get( 'wgPageName' ), action: 'purge' }),
mw.config.get( 'skin' ) == 'vector' ? 'Purge' : '*',
'ca-purge',
'Purge the server cache of this page',
null
);
}
if ( !$( '#ca-credits' ).length ) {
mw.util.addPortletLink(
'p-views',
mw.util.wikiScript() + '?' + $.param({ title: mw.config.get( 'wgPageName' ), action: 'credits' }),
mw.config.get( 'skin' ) == 'vector' ? 'Credits' : '*',
'ca-credits',
'',
null,
'#ca-watch, #ca-unwatch'
);
}
if ( !$( '#ca-render' ).length ) {
mw.util.addPortletLink(
'p-views',
mw.util.wikiScript() + '?' + $.param({ title: mw.config.get( 'wgPageName' ), action: 'render' }),
mw.config.get( 'skin' ) == 'vector' ? 'Render' : '*',
'ca-render',
'Render mode',
null,
'#ca-watch, #ca-unwatch'
);
}