User:Pokeswap/Test extension

From mediawiki.org

this is an extension which adds test to special:version


i need help changing this so there is a special page (special:TEST) which says "test "and that has a place to put text in, and all text goes to special:TESTtext and a checkbox which puts it in 2 categories (coding and other) and rights to remove text from special:TESTtext and other rights which are used to add to special:TEST (all by default) also, you can't add text directly to special:TESTtext but can delete it. all text for the page must be put in through special:TEST also an <addTEST> tag which would do something like <addTEST>text to be tested to see if it works in red<addTEST> and has all of that text in a special:TESTtextfromPage and that shows a picture of broken glass on the user's user page (for x amount of time determined by $wgglasstime)if the text has "failed". users with the kill right determine that using special:kill (if it has failed) or special:pass to submit it to special:passedcode (to be put on the site) also another page to hide all of or certain pages with <addTEST> (picked from a list) on it special:testing the test for an amount of time specified on hiding also the current wiki's code will be on a special page (special:code of wiki) where it will have a voting for pass or fail (code will not include localsettings.php)

the current code is:

 <?php
 if (!defined('MEDIAWIKI')) {
        echo <<<EOT
To install my extension, put the following line in LocalSettings.php:
require_once( "\$IP/extensions/TEST/TEST.php" );
EOT;
        exit( 1 );
}
 $wgExtensionCredits['specialpage'][] = array(
 
 'path' => __FILE__,
 
 'name' => 'TEST',
  
 'version' => '5',
 
 'author' => 'daniel keller',
 
 'url' => 'http://spyinginc.com/wiki',
 
 'descriptionmsg' => 'test-desc'
);
 
define popcorn as able to change text at the top of [[special:test]] define done as same as popcorn but need to be reviewed by sysop 


 $wgavailablerights = array ('done', 'popcorn', 'kill', 'codewiki', 'kickbanpage')

 $wgSpecialPages = array ('test'); // This will mean you have no other special pages
 
 $permit [popcorn]; // What is this? Where is the popcorn constant defined?

 $permit[DONE]; // What is this? Where is the DONE constant defined?

$wgGroupPermissions['spyinginc.com']['/wiki'] = true; //view all pages pages
$wgGroupPermissions['test']['DONE']= true; // to delete text
$wgGroupPermissions['test']['popcorn'] = true; //add text through [[special:TEST]]
$wgGroupPermissions['test']['kill'] = true; //for broken glass
$wgGroupPermissions['USE the vote']['codedwiki'] = true; // allows voting of code 
$wgGroupPermissions['test']['kickbanpage'] = true; // can alter if content is relevent no matter what.

$wgcaptchatriggers [TEST] = true

$dir = dirname(__FILE__) . '/';
$wgAutoloadClasses['SpecialTEST'] = $dir . 'SpecialTEST.php'; # Location of the SpecialTEST class (Tell MediaWiki to load this file)
$wgExtensionMessagesFiles[TEST'] = $dir . 'TEST.i18n.php'; # Location of a messages file (Tell MediaWiki to load this file)
$wgExtensionMessagesFiles['TESTAlias'] = $dir . 'TEST.alias.php'; # Location of an aliases file (Tell MediaWiki to load this file)
$wgSpecialPages['TEST'] = 'SpecialTEST'; # Tell MediaWiki about the new special page and its class 

$wgSpecialPageGroups['TEST'] = 'other';