Index: trunk/phase3/includes/AutoLoader.php |
— | — | @@ -659,6 +659,7 @@ |
660 | 660 | 'SpecialExport' => 'includes/specials/SpecialExport.php', |
661 | 661 | 'SpecialFilepath' => 'includes/specials/SpecialFilepath.php', |
662 | 662 | 'SpecialImport' => 'includes/specials/SpecialImport.php', |
| 663 | + 'SpecialListFiles' => 'includes/specials/SpecialListfiles.php', |
663 | 664 | 'SpecialListGroupRights' => 'includes/specials/SpecialListgrouprights.php', |
664 | 665 | 'SpecialListusers' => 'includes/specials/SpecialListusers.php', |
665 | 666 | 'SpecialLockdb' => 'includes/specials/SpecialLockdb.php', |
Index: trunk/phase3/includes/specials/SpecialListfiles.php |
— | — | @@ -21,15 +21,23 @@ |
22 | 22 | * @ingroup SpecialPage |
23 | 23 | */ |
24 | 24 | |
25 | | -function wfSpecialListfiles( $par = null ) { |
26 | | - global $wgOut; |
| 25 | +class SpecialListFiles extends SpecialPage { |
27 | 26 | |
28 | | - $pager = new ImageListPager( $par ); |
| 27 | + public function __construct(){ |
| 28 | + parent::__construct( 'Listfiles' ); |
| 29 | + } |
29 | 30 | |
30 | | - $limit = $pager->getForm(); |
31 | | - $body = $pager->getBody(); |
32 | | - $nav = $pager->getNavigationBar(); |
33 | | - $wgOut->addHTML( "$limit<br />\n$body<br />\n$nav" ); |
| 31 | + public function execute( $par ){ |
| 32 | + global $wgOut; |
| 33 | + $this->setHeaders(); |
| 34 | + |
| 35 | + $pager = new ImageListPager( $par ); |
| 36 | + |
| 37 | + $limit = $pager->getForm(); |
| 38 | + $body = $pager->getBody(); |
| 39 | + $nav = $pager->getNavigationBar(); |
| 40 | + $wgOut->addHTML( "$limit<br />\n$body<br />\n$nav" ); |
| 41 | + } |
34 | 42 | } |
35 | 43 | |
36 | 44 | /** |
Index: trunk/phase3/includes/SpecialPage.php |
— | — | @@ -162,7 +162,7 @@ |
163 | 163 | 'Tags' => 'SpecialTags', |
164 | 164 | |
165 | 165 | # Media reports and uploads |
166 | | - 'Listfiles' => array( 'SpecialPage', 'Listfiles' ), |
| 166 | + 'Listfiles' => 'SpecialListFiles', |
167 | 167 | 'Filepath' => 'SpecialFilepath', |
168 | 168 | 'MIMEsearch' => 'MIMEsearchPage', |
169 | 169 | 'FileDuplicateSearch' => 'FileDuplicateSearchPage', |