Use the new unified functions for building user tools links.
authorRob Church <robchurch@users.mediawiki.org>
Wed, 22 Mar 2006 22:03:09 +0000 (22:03 +0000)
committerRob Church <robchurch@users.mediawiki.org>
Wed, 22 Mar 2006 22:03:09 +0000 (22:03 +0000)
includes/SpecialNewpages.php

index 089ce44..37de1b6 100644 (file)
@@ -77,12 +77,6 @@ class NewPagesPage extends QueryPage {
                $ut = $result->user_text;
 
                $length = wfMsgHtml( 'nbytes', htmlspecialchars( $wgLang->formatNum( $result->length ) ) );
-
-               $userLink  = $skin->makeLinkObj( Title::makeTitle( NS_USER, $ut ), htmlspecialchars( $ut ) );
-               $talkLink  = $skin->makeLinkObj( Title::makeTitle( NS_USER_TALK, $ut ), htmlspecialchars( $wgLang->getNsText( NS_TALK ) ) );
-               $contLink  = $skin->makeKnownLinkObj( Title::makeTitle( NS_SPECIAL, "Contributions/$ut" ), wfMsgHtml( 'contribslink' ) );
-               $userTools = "$userLink ($talkLink | $contLink)";
-
                $d = $wgLang->timeanddate( $result->timestamp, true );
 
                # Since there is no diff link, we need to give users a way to
@@ -94,6 +88,8 @@ class NewPagesPage extends QueryPage {
                        $link = $skin->makeKnownLink( $ns . ':' . $result->title, '' );
                }
 
+               $userTools = $skin->userLink( $u, $ut ) . $skin->userToolLinks( $u, $ut );
+
                $s = "{$d} {$link} ({$length}) . . {$userTools}";
                $s .= $skin->commentBlock( $result->comment );
                return $s;