* Really support for getting new pages from other namespaces than NS_MAIN
authorÆvar Arnfjörð Bjarmason <avar@users.mediawiki.org>
Sat, 8 Oct 2005 15:36:21 +0000 (15:36 +0000)
committerÆvar Arnfjörð Bjarmason <avar@users.mediawiki.org>
Sat, 8 Oct 2005 15:36:21 +0000 (15:36 +0000)
includes/SpecialNewpages.php

index 977ec3e..1f8f067 100644 (file)
@@ -78,12 +78,13 @@ class NewPagesPage extends QueryPage {
 
                # Since there is no diff link, we need to give users a way to
                # mark the article as patrolled if it isn't already
+               $ns = $wgContLang->getNsText( $result->namespace );
                if ( $wgUseRCPatrol && !is_null ( $result->usepatrol ) && $result->usepatrol &&
                     $result->patrolled == 0 && $wgUser->isLoggedIn() &&
                     ( $wgUser->isAllowed('patrol') || !$wgOnlySysopsCanPatrol ) )
-                       $link = $skin->makeKnownLink( $result->title, '', "rcid={$result->rcid}" );
+                       $link = $skin->makeKnownLink( $ns . ':' . $result->title, '', "rcid={$result->rcid}" );
                else
-                       $link = $skin->makeKnownLink( $result->title, '' );
+                       $link = $skin->makeKnownLink( $ns . ':' . $result->title, '' );
 
                $s = "{$d} {$link} ({$length}) . . {$ul}";