* Fixed unclosed <p> tag
[lhc/web/wiklou.git] / includes / SpecialAncientpages.php
index c847e1e..a9a4231 100644 (file)
@@ -22,7 +22,7 @@ class AncientPagesPage extends QueryPage {
        }
 
        function isExpensive() {
-               return parent::isExpensive() ;
+               return true;
        }
        
        function isSyndicated() { return false; }
@@ -36,9 +36,9 @@ class AncientPagesPage extends QueryPage {
                        "SELECT 'Ancientpages' as type,
                                        page_namespace as namespace,
                                page_title as title,
-                               rev_timestamp as value
+                               UNIX_TIMESTAMP(rev_timestamp) as value
                        FROM $page, $revision
-                       WHERE page_namespace=0 AND page_is_redirect=0
+                       WHERE page_namespace=".NS_MAIN." AND page_is_redirect=0
                          AND page_latest=rev_id";
        }
        
@@ -50,7 +50,8 @@ class AncientPagesPage extends QueryPage {
                global $wgLang, $wgContLang;
 
                $d = $wgLang->timeanddate( wfTimestamp( TS_MW, $result->value ), true );
-               $link = $skin->makeKnownLink( $result->title, $wgContLang->convert( $result->title) );
+               $title = Title::makeTitle( $result->namespace, $result->title );
+               $link = $skin->makeKnownLinkObj( $title, $wgContLang->convert( $title->getPrefixedText() ) );
                return "{$link} ({$d})";
        }
 }