User:Tom29739/archiver.js

userIsInGroup = function ( group ) { return $.inArray(group, mw.config.get( 'wgUserGroups' )) !== -1; }; if (userIsInGroup( "autoconfirmed" ) || stuff.userIsInGroup( "confirmed" )) { var pagename = mw.config.get("wgPageName"); var url = "//tools.wmflabs.org/hall-of-fame/api.php?pageURL=" + pagename; // Create portlet link var archive = mw.util.addPortletLink( 'p-cactions', url,	'Archive', 'ca-archive-stuff',	'Click here to archive this page' ); var testurl = "//tools.wmflabs.org/hall-of-fame/apitest.php?pageURL=" + pagename; // Create portlet link var archive = mw.util.addPortletLink( 'p-cactions', testurl,	'Test archive', 'ca-archive-stuff',	'Click here to test archive this page' ); }