Add block link to Special:Contributions
authorRob Church <robchurch@users.mediawiki.org>
Sat, 21 Jan 2006 23:08:34 +0000 (23:08 +0000)
committerRob Church <robchurch@users.mediawiki.org>
Sat, 21 Jan 2006 23:08:34 +0000 (23:08 +0000)
RELEASE-NOTES
includes/SpecialContributions.php

index 45f0966..e657ec5 100644 (file)
@@ -329,6 +329,7 @@ Special Pages:
 * Move parentheses out of <a> link in Special:Contributions
 * (bug 3192): properly check 'limit' parameter on Special:Contributions
 * (bug 3187) watchlist text refer to unexistent "Stop watching" action
+* Add block link to Special:Contributions
 
 Misc.:
 * PHP 4.1 compatibility fix: don't use new_link parameter to mysql_connect
index e34d103..518fee6 100644 (file)
@@ -224,7 +224,11 @@ function wfSpecialContributions( $par = null ) {
        }
        $talk = $nt->getTalkPage();
        if( $talk ) {
-               $ul .= ' (' . $sk->makeLinkObj( $talk, $wgLang->getNsText( NS_TALK ) ) . ')';
+               $ul .= ' (' . $sk->makeLinkObj( $talk, $wgLang->getNsText( NS_TALK ) );
+               if( $wgUser->isAllowed( 'block' ) ) {
+                       $ul .= ' | ' . $sk->makeLinkObj( Title::makeTitle( NS_SPECIAL, 'Blockip/' . $nt->getText() ), wfMsgHtml( 'blocklink' ) );
+               }
+               $ul .= ')';
        }
 
        if ($target == 'newbies') {