Index: trunk/phase3/includes/AutoLoader.php |
— | — | @@ -609,6 +609,8 @@ |
610 | 610 | 'SpecialMostlinkedtemplates' => 'includes/specials/SpecialMostlinkedtemplates.php', |
611 | 611 | 'SpecialPreferences' => 'includes/specials/SpecialPreferences.php', |
612 | 612 | 'SpecialPrefixindex' => 'includes/specials/SpecialPrefixindex.php', |
| 613 | + 'SpecialProtectedpages' => 'includes/specials/SpecialProtectedpages.php', |
| 614 | + 'SpecialProtectedtitles' => 'includes/specials/SpecialProtectedtitles.php', |
613 | 615 | 'SpecialRandomredirect' => 'includes/specials/SpecialRandomredirect.php', |
614 | 616 | 'SpecialRecentChanges' => 'includes/specials/SpecialRecentchanges.php', |
615 | 617 | 'SpecialRecentchangeslinked' => 'includes/specials/SpecialRecentchangeslinked.php', |
Index: trunk/phase3/includes/specials/SpecialProtectedtitles.php |
— | — | @@ -26,17 +26,20 @@ |
27 | 27 | * |
28 | 28 | * @ingroup SpecialPage |
29 | 29 | */ |
30 | | -class ProtectedTitlesForm { |
| 30 | +class SpecialProtectedtitles extends SpecialPage { |
31 | 31 | |
32 | 32 | protected $IdLevel = 'level'; |
33 | 33 | protected $IdType = 'type'; |
34 | 34 | |
35 | | - function showList( $msg = '' ) { |
| 35 | + public function __construct() { |
| 36 | + parent::__construct( 'Protectedtitles' ); |
| 37 | + } |
| 38 | + |
| 39 | + function execute( $par ) { |
36 | 40 | global $wgOut, $wgRequest; |
37 | 41 | |
38 | | - if ( $msg != "" ) { |
39 | | - $wgOut->setSubtitle( $msg ); |
40 | | - } |
| 42 | + $this->setHeaders(); |
| 43 | + $this->outputHeader(); |
41 | 44 | |
42 | 45 | // Purge expired entries on one in every 10 queries |
43 | 46 | if ( !mt_rand( 0, 10 ) ) { |
Index: trunk/phase3/includes/specials/SpecialProtectedpages.php |
— | — | @@ -26,17 +26,20 @@ |
27 | 27 | * |
28 | 28 | * @ingroup SpecialPage |
29 | 29 | */ |
30 | | -class ProtectedPagesForm { |
| 30 | +class SpecialProtectedpages extends SpecialPage { |
31 | 31 | |
32 | 32 | protected $IdLevel = 'level'; |
33 | 33 | protected $IdType = 'type'; |
34 | 34 | |
35 | | - public function showList( $msg = '' ) { |
| 35 | + public function __construct() { |
| 36 | + parent::__construct( 'Protectedpages' ); |
| 37 | + } |
| 38 | + |
| 39 | + public function execute( $par ) { |
36 | 40 | global $wgOut, $wgRequest; |
37 | 41 | |
38 | | - if( $msg != "" ) { |
39 | | - $wgOut->setSubtitle( $msg ); |
40 | | - } |
| 42 | + $this->setHeaders(); |
| 43 | + $this->outputHeader(); |
41 | 44 | |
42 | 45 | // Purge expired entries on one in every 10 queries |
43 | 46 | if( !mt_rand( 0, 10 ) ) { |
— | — | @@ -352,11 +355,3 @@ |
353 | 356 | return 'pr_id'; |
354 | 357 | } |
355 | 358 | } |
356 | | - |
357 | | -/** |
358 | | - * Constructor |
359 | | - */ |
360 | | -function wfSpecialProtectedpages() { |
361 | | - $ppForm = new ProtectedPagesForm(); |
362 | | - $ppForm->showList(); |
363 | | -} |
Index: trunk/phase3/includes/SpecialPage.php |
— | — | @@ -92,8 +92,8 @@ |
93 | 93 | 'Lonelypages' => array( 'SpecialPage', 'Lonelypages' ), |
94 | 94 | 'Fewestrevisions' => array( 'SpecialPage', 'Fewestrevisions' ), |
95 | 95 | 'Withoutinterwiki' => array( 'SpecialPage', 'Withoutinterwiki' ), |
96 | | - 'Protectedpages' => array( 'SpecialPage', 'Protectedpages' ), |
97 | | - 'Protectedtitles' => array( 'SpecialPage', 'Protectedtitles' ), |
| 96 | + 'Protectedpages' => 'SpecialProtectedpages', |
| 97 | + 'Protectedtitles' => 'SpecialProtectedtitles', |
98 | 98 | 'Shortpages' => array( 'SpecialPage', 'Shortpages' ), |
99 | 99 | 'Uncategorizedcategories' => array( 'SpecialPage', 'Uncategorizedcategories' ), |
100 | 100 | 'Uncategorizedimages' => array( 'SpecialPage', 'Uncategorizedimages' ), |