<?php
/**
* Contain a class for special pages
+ * @package MediaWiki
*/
/**
* we factor out some of the functionality into a superclass, and let
* subclasses derive from it.
*
+ * @package MediaWiki
*/
class QueryPage {
-
+
/**
* Subclasses return their name here. Make sure the name is also
* specified in SpecialPage.php and in Language.php as a language message
/**
* Subclasses return an SQL query here.
- *
+ *
* Note that the query itself should return the following four columns:
* 'type' (your special page's name), 'namespace', 'title', and 'value'
* *in that order*. 'value' is used for sorting.
function formatResult( $skin, $result ) {
return '';
}
-
+
/**
* The content returned by this function will be output before any result
*/
}
}
if ( $res === false ) {
- $res = $dbr->query( $sql . $this->getOrder() .
+ $res = $dbr->query( $sql . $this->getOrder() .
$dbr->limitResult( $limit,$offset ), $fname );
$num = $dbr->numRows($res);
}
$sk = $wgUser->getSkin( );
-
+
$wgOut->addHTML( $this->getPageHeader() );
$top = wfShowingResults( $offset, $num);
}
function feedDesc() {
- return wfMsg( 'fromwikipedia' );
+ return wfMsg( 'tagline' );
}
function feedUrl() {
* This is a subclass for very simple queries that are just looking for page
* titles that match some criteria. It formats each result item as a link to
* that page.
+ *
+ * @package MediaWiki
*/
class PageQueryPage extends QueryPage {