Merge "SkinTemplate: extract formatLanguageName() from outputPage()"
[lhc/web/wiklou.git] / includes / specials / SpecialAncientpages.php
index 680a948..fc5df4f 100644 (file)
@@ -36,14 +36,16 @@ class AncientPagesPage extends QueryPage {
                return true;
        }
 
-       function isSyndicated() { return false; }
+       function isSyndicated() {
+               return false;
+       }
 
        function getQueryInfo() {
                return array(
                        'tables' => array( 'page', 'revision' ),
-                       'fields' => array( 'page_namespace AS namespace',
-                                       'page_title AS title',
-                                       'rev_timestamp AS value' ),
+                       'fields' => array( 'namespace' => 'page_namespace',
+                                       'title' => 'page_title',
+                                       'value' => 'rev_timestamp' ),
                        'conds' => array( 'page_namespace' => MWNamespace::getContentNamespaces(),
                                        'page_is_redirect' => 0,
                                        'page_latest=rev_id' )
@@ -61,12 +63,12 @@ class AncientPagesPage extends QueryPage {
        function formatResult( $skin, $result ) {
                global $wgContLang;
 
-               $d = $this->getLang()->timeanddate( wfTimestamp( TS_MW, $result->value ), true );
+               $d = $this->getLanguage()->userTimeAndDate( $result->value, $this->getUser() );
                $title = Title::makeTitle( $result->namespace, $result->title );
                $link = Linker::linkKnown(
                        $title,
                        htmlspecialchars( $wgContLang->convert( $title->getPrefixedText() ) )
                );
-               return wfSpecialList( $link, htmlspecialchars( $d ) );
+               return $this->getLanguage()->specialList( $link, htmlspecialchars( $d ) );
        }
 }