MediaWiki
REL1_19
|
SpecialPage: handling special pages and lists thereof. More...
Go to the source code of this file.
Classes | |
class | SpecialPageFactory |
Factory for handling the special page list and generating SpecialPage objects. More... |
SpecialPage: handling special pages and lists thereof.
To add a special page in an extension, add to $wgSpecialPages either an object instance or an array containing the name and constructor parameters. The latter is preferred for performance reasons.
The object instantiated must be either an instance of SpecialPage or a sub-class thereof. It must have an execute() method, which sends the HTML for the special page to $wgOut. The parent class has an execute() method which distributes the call to the historical global functions. Additionally, execute() also checks if the user has the necessary access privileges and bails out if not.
To add a core special page, use the similar static list in SpecialPage::$mList. To remove a core static special page at runtime, use a SpecialPage_initList hook.
Definition in file SpecialPageFactory.php.