User:TeleComNasSprVen/common.js
Jump to navigation
Jump to search
Note: After saving, changes may not occur immediately. Click here to learn how to bypass your browser's cache.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (Cmd-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (Cmd-Shift-R on a Mac)
- Internet Explorer: Hold Ctrl while clicking Refresh, or press Ctrl-F5
- Opera: Clear the cache in Tools → Preferences
For details and instructions about other browsers, see Wikipedia:Bypass your cache.
Code that you insert on this page could contain malicious content capable of compromising your account. If you are unsure whether code you are adding to this page is safe, you can ask at the central discussion page, Scriptorium. The code will be executed when previewing this page under some skins, including Monobook. You can in the interim if you wish to refresh the content sooner under another skin. |
The accompanying .css page for this skin is at User:TeleComNasSprVen/common.css. |
// <syntaxhighlight lang="javascript">
// Bunch of imported scripts
// [[File:Krinkle_CVNSimpleOverlay_wiki.js]]
// by [[:meta:User:Krinkle|User:Krinkle]] at [[:meta:Main Page|Meta-Wiki]]
mw.loader.load('https://meta.wikimedia.org/w/index.php?title=User:Krinkle/Scripts/CVNSimpleOverlay_wiki.js&action=raw&ctype=text/javascript');
// TemplatePreloader gadget, see [[Help:Header preloading script gadget]] and [[Template:header]]
mw.loader.load('https://en.wikisource.org/w/index.php?title=MediaWiki:Gadget-TemplatePreloader.js&action=raw&ctype=text/javascript');
// HotCat gadget from [[:commons:Main Page|CommonsWiki]]
mw.loader.load('https://commons.wikimedia.org/w/index.php?title=MediaWiki:Gadget-HotCat.js&action=raw&ctype=text/javascript');
/*
PurgeTab link gadget, from [[MediaWiki:Gadget-PurgeTab.js]]
Action link: Purge (Action menu)
@source: www.mediawiki.org/wiki/Snippets/Purge_action
@rev: 6
*/
$( function() {
if ( !$( '#ca-purge' ).length && mw.config.get( 'wgIsArticle' ) ) {
mw.util.addPortletLink(
'p-cactions',
mw.util.getUrl( mw.config.get( 'wgPageName' ), { action: 'purge' } ),
'purge',
'ca-purge',
'Purge the server cache of this page'
);
}
});
/*
UserMessages gadget, to welcome new users and IP users
Main code by [[User:Siebrand]], derived from [[MediaWiki:Quick-delete.js]] by
[[:en:User:Jietse Niesen|Jietse Niesen]], [[User:pfctdayelise|pfctdayelise]] and
[[User:Alphax|Alphax]].
Code stolen from Commons by [[User:ShakataGaNai]] for Wikinews (Fixed by Bawolff)
* [[:Category:Block templates]]
* [[:Category:User_talk_templates]]
*/
mw.loader.load('https://en.wikisource.org/w/index.php?title=MediaWiki:Gadget-UserMessages.js&action=raw&ctype=text/javascript');
/*
WSexport tool from [[MediaWiki:Gadget-WSexport.js]] and hosted on the toolserver
Adds a "Download as EPUB" link to the sidebar
Generates and starts a download of the current page as an EPUB file.
Subpages of the current page (if any) are included as well.
Uses the WSExport tool on Toolserver: http://toolserver.org/~tpt/wsexport/book.php
See Oldwikisource:Wikisource:WSexport for more information
Bug reports should go to fr:Wikisource:Wsexport
Tool source code at https://github.com/wsexport
*/
if (wgNamespaceNumber == 0 || wgNamespaceNumber == 114) {
$(document).ready( function () {
mw.util.addPortletLink(
'p-coll-print_export',
'https://wsexport.wmflabs.org/tool/book.php?lang=en&format=epub&page=' + mw.config.get('wgPageName'),
'Download as EPUB',
'n-epubExport',
'Download an EPUB version of this page',
'',
'#t-print');
});
}
// Adds User Rights link to sidebar.
mw.util.addPortletLink('p-tb', 'https://en.wikisource.org/w/index.php?title=Special:ListUsers&limit=1&username=' + wgRelevantUserName, "User rights", "t-userrights", "Show user permissions")
// </syntaxhighlight>