User:Knakveey/global.js

/* Portable Infoboxes project */ $(document).ready(function {	$('.AccountNavigation .user-menu').prepend('Enable PI');	$('.AccountNavigation .user-menu').on('click', '#quick-ib', function { var cityID = mediaWiki.config.get('wgCityId'); var dataPI = { action: "ajax", rs: "axWFactorySaveVariable", cityid: cityID, varCityid: cityID, varType: 'boolean', varName: 'wgEnableInsightsInfoboxes', varId: 1513, varValue: 1, reason: "Enabling portable infobox extension", tagname: ''} var dataDraft = { action: "ajax", rs: "axWFactorySaveVariable", cityid: cityID, varCityid: cityID, varType: 'boolean', varName: 'wgEnableTemplateDraftExt', varId: 1516, varValue: 1, reason: "Enabling template draft extension", tagname: ''} $.ajax({			type: "POST",			url: 'http://community.wikia.com/index.php',			data: dataPI,			dataType: "jsonp",		}); $.ajax({			type: "POST",			url: 'http://community.wikia.com/index.php',			data: dataDraft,			dataType: "jsonp",		}); $('div.WikiaPageContentWrapper').prepend(' Extensions enabled.'); }); });