removed non-matching wfProfileOut() calls
[mediawiki.git] / includes / SpecialCategories.php
blob6cc493e7ccdf559c7bf5aabdde7e147e1ca604f9
1 <?php
3 require_once("QueryPage.php");
5 class CategoriesPage extends QueryPage {
7 function getName() {
8 return "Categories";
11 function isExpensive() {
12 return false;
15 function getSQL() {
16 $NScat = NS_CATEGORY;
17 return "SELECT DISTINCT 'Categories' as type,
18 {$NScat} as namespace,
19 cl_to as title,
20 1 as value
21 FROM categorylinks";
24 function sortDescending() {
25 return false;
28 function formatResult( $skin, $result ) {
29 global $wgLang;
30 $title = Title::makeTitle( NS_CATEGORY, $result->title );
31 return $skin->makeLinkObj( $title, $title->getText() );
35 function wfSpecialCategories()
37 list( $limit, $offset ) = wfCheckLimits();
39 $cap = new CategoriesPage();
41 return $cap->doQuery( $offset, $limit );