'Version' => new SpecialPage( 'Version' ),
'Allmessages' => new SpecialPage( 'Allmessages' ),
'Log' => new SpecialPage( 'Log' ),
- 'Block' => new SpecialPage( 'Blockip', 'block' ),
- 'Undelete' => new SpecialPage( 'Undelete' ),
+ 'Blockip' => new SpecialPage( 'Blockip', 'block' ),
+ 'Undelete' => new SpecialPage( 'Undelete', 'deletedhistory' ),
"Import" => new SpecialPage( "Import", 'import' ),
'Lockdb' => new SpecialPage( 'Lockdb', 'siteadmin' ),
'Unlockdb' => new SpecialPage( 'Unlockdb', 'siteadmin' ),
'Userrights' => new SpecialPage( 'Userrights', 'userrights' ),
'MIMEsearch' => new SpecialPage( 'MIMEsearch' ),
+ 'Unwatchedpages' => new SpecialPage( 'Unwatchedpages', 'unwatchedpages' ),
+ 'Listredirects' => new SpecialPage( 'Listredirects' )
);
-if ( $wgUseValidation )
- $wgSpecialPages['Validate'] = new SpecialPage( 'Validate' );
-
if( !$wgDisableCounters ) {
$wgSpecialPages['Popularpages'] = new SpecialPage( 'Popularpages' );
}
$wgSpecialPages['Confirmemail'] = new UnlistedSpecialPage( 'Confirmemail' );
}
-if ( $wgEnableUnwatchedpages )
- $wgSpecialPages['Unwatchedpages'] = new SpecialPage( 'Unwatchedpages' );
-
/**
* Parent special page class, also static functions for handling the special
* page list
'Mytalk' => Title::makeTitle( NS_USER_TALK, $wgUser->getName() ),
'Mycontributions' => Title::makeTitle( NS_SPECIAL, 'Contributions/' . $wgUser->getName() ),
'Listadmins' => Title::makeTitle( NS_SPECIAL, 'Listusers/sysop' ), # @bug 2832
- 'Randompage' => Title::makeTitle( NS_SPECIAL, 'Random' ),
- 'Blockip' => Title::makeTitle( NS_SPECIAL, 'Block' )
+ 'Randompage' => Title::makeTitle( NS_SPECIAL, 'Random' )
);
wfRunHooks( 'SpecialPageGetRedirect', array( &$redirects ) );
function getPages() {
global $wgSpecialPages;
$pages = array(
- '' => array(),
- 'sysop' => array(),
- 'developer' => array()
+ '' => array(),
+ 'sysop' => array(),
+ 'developer' => array()
);
foreach ( $wgSpecialPages as $name => $page ) {
function getFile() { return $this->mFile; }
function isListed() { return $this->mListed; }
/**#@-*/
-
+
/**#@+
* Accessor and mutator
*/
function includable( $x = NULL ) { return wfSetVar( $this->mIncludable, $x ); }
function including( $x = NULL ) { return wfSetVar( $this->mIncluding, $x ); }
/**#@-*/
-
+
/**
* Checks if the given user (identified by an object) can execute this
* special page (as defined by $mRestriction)
if(!function_exists($func) and $this->mFile) {
require_once( $this->mFile );
}
- $this->outputHeader();
+ if ( wfRunHooks( 'SpecialPageExecuteBeforeHeader', array( &$this, &$par, &$func ) ) )
+ $this->outputHeader();
+ if ( ! wfRunHooks( 'SpecialPageExecuteBeforePage', array( &$this, &$par, &$func ) ) )
+ return;
$func( $par, $this );
+ if ( ! wfRunHooks( 'SpecialPageExecuteAfterPage', array( &$this, &$par, &$func ) ) )
+ return;
} else {
$this->displayRestrictionError();
}