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.
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.
/* Uploaded from https://github.com/WPAFC/afch-rewrite, commit: fff341a397ca8da111f2e8c1bad547ba6bee0842 (shortdesc) *///<nowiki>(function(){// Check that we're in the right namespace and on the right pageswitch(mw.config.get('wgNamespaceNumber')){case4:// Wikipediacase5:// Wikipedia talkvarpageName=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;case2:// Usercase118:// Draftbreak;default:return;}// Initialize the AFCH objectwindow.AFCH={};// Set up constantsAFCH.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=true;AFCH.consts.baseurl=AFCH.consts.scriptpath+'?action=raw&ctype=text/javascript&title=User:Enterprisey/afch-dev.js';$.when($.getScript(AFCH.consts.baseurl+'/core.js'),$.getScript('https://tools-static.wmflabs.org/cdnjs/ajax/libs/hogan.js/3.0.2/hogan.min.js')).done(function(){varloaded=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>