User:Swizzl3d/wikia.js

// // GEMH popups (test) importScript('User:Quarenon/gemhpop.js');; // Begin TemplatesToolbar script var toolbarTemplates = []; var toolbarFillSummary = 1; var toolbarFillHeader = 1; // Begin custom templates /* Basic syntax -- Use '*' for all namespaces -- Use 'main' for the (main) namespace -- Use 'project'/'project talk' for the RuneScape/RuneScape talk namespaces -- In the sample text, the magic word, '__CONTENTPAGE__', can be used to refer to the last non-talk and non-special page viewed -- For further help with this script, visit http://runescape.wikia.com/wiki/User:Quarenon/Scripts/Templates toolbarTemplates.push({ name: 'Template Name', ns: 'file', open: 'Opening markup', close: 'Closing markup', sample: 'Text between opening and closing markup' }); // All namespaces toolbarTemplates.push({ name: 'Skill clickpic', ns: '*', open: '', sample: 'skill' }); // Template: namespace toolbarTemplates.push({ name: 'Doc', ns: 'tempate', open: , close: , sample: '' }); /* brokened // Calcs (template/user) toolbarTemplates.push({ name: 'Includeonly', ns: 'tempate|user', open: ' ', close: ' ', sample: '' }); toolbarTemplates.push({ name: 'Noinclude', ns: 'tempate|user', open: ' ', close: ' ', sample: '' }); toolbarTemplates.push({ name: 'Onlyinclude', ns: 'tempate|user', open: ' ', close: ' ', sample: '' }); // File: namespace toolbarTemplates.push({ name: 'GIF derived', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Anti-aliasing artifacts', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Anti-aliasing needed', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Fair use', ns: 'file', open: '', sample: 'Jagex' }); toolbarTemplates.push({ name: 'Jpeg', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Obsolete file', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Game Guide image', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Transparency needed', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Crop needed', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Standard detail', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Historical image', ns: 'file', open: '', sample: 'reason' }); toolbarTemplates.push({ name: 'Jagex image', ns: 'file', open: , close: , sample: '' }); toolbarTemplates.push({ name: 'Pre-animation pack', ns: 'file', open: '', sample: 'number' }); toolbarTemplates.push({ name: 'No transparency', ns: 'file', open: '', sample: 'number' }); // End custom templates importScript('User:Quarenon/templates.js'); // End TemplatesToolbar script //@@@ 'borrowed' from http://runescape.wikia.com/wiki/User:Ryan_PM/wikia.js //Add links to Toolbar if ( wgNamespaceNumber !=401 && !window.ToolbarLinksLoad ) { addOnloadHook( addToolbarLinks ); } var ToolbarLinksLoad = true; // prevent duplication function addToolbarLinks { $('Wikia JS').appendTo('ul.tools'); $('Wikia CSS').appendTo('ul.tools'); $('Yew Grove').appendTo('ul.tools'); $('<a href="/wiki/RuneScape:User_help">User help<img src="http://upload.wikimedia.org/wikipedia/commons/6/65/Crystal_Clear_app_xchat.png" width="15" height="15" align="left" border="0"></a></li>').appendTo('ul.tools'); $('<a href="/wiki/RuneScape:Administrator_requests">Admin requests<img src="http://upload.wikimedia.org/wikipedia/commons/0/0a/Crystal_Clear_kdmconfig-danger.png" width="15" height="15" align="left" border="0"></a></li>').appendTo('ul.tools'); $('<a href="/wiki/Special:SpecialPages">Special pages<img src="http://upload.wikimedia.org/wikipedia/commons/2/27/Crystal_Clear_app_musicstore.png" width="15" height="15" align="left" border="0"></a></li>').appendTo('ul.tools'); $('<a href="/wiki/Special:RecentChanges">Recent Changes<img src="http://upload.wikimedia.org/wikipedia/commons/3/31/Crystal_Clear_app_antivirus.png" width="15" height="15" align="left" border="0"></a></li>').appendTo('ul.tools'); } //Add links to Global Navigation if ( wgNamespaceNumber !=401 && !window.GlobalLinksLoad ) { addOnloadHook( addGlobalLinks ); } var GlobalLinksLoad = true; // prevent duplication function addGlobalLinks { $('<a href="http://www.runescape.com/title.ws"> RS<img src="http://images2.wikia.nocookie.net/__cb20101108182242/runescape/images/6/67/Category_sword.png" width="20" height="20" align="left" border="0"></a></li>').appendTo('ul.GlobalNavigation'); $('<a href="http://community.wikia.com/wiki/Blog:Wikia_Staff_Blog"> Community Central<img src="http://upload.wikimedia.org/wikipedia/commons/d/db/Crystal_Clear_app_kblackbox.png" width="20" height="20" align="left" border="0"></a></li>').appendTo('ul.GlobalNavigation'); $('<a href="http://trac.wikia-code.com/browser"> Trac Code<img src="http://upload.wikimedia.org/wikipedia/commons/1/1a/Crystal_Clear_app_terminal.png" width="20" height="20" align="left" border="0"></a></li>').appendTo('ul.GlobalNavigation'); $('<a href="http://www.mediawiki.org/wiki/MediaWiki"> MediaWiki<img src="http://upload.wikimedia.org/wikipedia/commons/4/4b/Crystal_Clear_app_filetypes.png" width="20" height="20" align="left" border="0"></a></li>').appendTo('ul.GlobalNavigation'); } //Add links to Account Navigation if ( wgNamespaceNumber !=401 && !window.AccLinksLoad ) { addOnloadHook( addAccLinks ); } var AccLinksLoad = true; // prevent duplication function addAccLinks { $('<a href="/wiki/Special:Contributions/Gaz_Lloyd">Contributions</a></li>').appendTo('.AccountNavigation > li > ul.subnav'); } //Test //Add links to Global Navigation if ( wgNamespaceNumber !=401 && !window.MenuButtonLoad ) { addOnloadHook( addMenuButtons ); } var MenuButtonLoad = true; // prevent duplication function addMenuButtons { $('<a href="/index.php?title='+encodeURIComponent(wgPageName)+'&action=history">History</a></li>').appendTo('ul.wikia-menu-button > li > ul'); $('<a href="/index.php?title='+encodeURIComponent(wgPageName)+'&action=Purge">Purge</a></li>').appendTo('ul.wikia-menu-button > li > ul'); } //re-add namespace to header if ( wgNamespaceNumber == 2 || wgNamespaceNumber == 3 ) { document.getElementById('WikiaUserPagesHeader').getElementsByTagName("h1")[0].innerHTML = wgCanonicalNamespace + ":" + wgTitle; } else if ( wgNamespaceNumber !== 0 ) { document.getElementById('WikiaPageHeader').getElementsByTagName("h1")[0].innerHTML = wgCanonicalNamespace + ":" + wgTitle; } //