wiki.techinc.nl/includes/PageQueryPage.php
Antoine Musso a600f8a781 revert core part of r111231
That one removed wfLoadExtensionMessages() . We do not want to break
back compatiliblity right now.
2012-02-12 19:40:13 +00:00

26 lines
639 B
PHP

<?php
/**
* Variant of QueryPage which formats the result as a simple link to the page
*
* @ingroup SpecialPage
*/
abstract class PageQueryPage extends QueryPage {
/**
* Format the result as a simple link to the page
*
* @param $skin Skin
* @param $row Object: result row
* @return string
*/
public function formatResult( $skin, $row ) {
global $wgContLang;
$title = Title::makeTitleSafe( $row->namespace, $row->title );
$text = $row->title;
if ( $title instanceof Title ) {
$text = $wgContLang->convert( $title->getPrefixedText() );
}
return Linker::linkKnown( $title, htmlspecialchars( $text ) );
}
}