Cleaned up some PHP coding style issues, and a few problems with
authorCharles Melbye <charlie@users.mediawiki.org>
Tue, 4 Nov 2008 01:53:48 +0000 (01:53 +0000)
committerCharles Melbye <charlie@users.mediawiki.org>
Tue, 4 Nov 2008 01:53:48 +0000 (01:53 +0000)
bug 15868. Patch by NSK Nikolaos S. Karastathis.

skins/Nostalgia.php

index b713cf3..2b9b2f6 100644 (file)
@@ -57,7 +57,7 @@ class SkinNostalgia extends Skin {
                $sep = " |\n";
 
                $s = $this->mainPageLink() . $sep
-                 . $this->specialLink( "recentchanges" );
+                 . $this->specialLink( 'recentchanges' );
 
                if ( $wgOut->isArticle() ) {
                        $s .=  $sep . $this->editThisPage()
@@ -67,14 +67,30 @@ class SkinNostalgia extends Skin {
                /* show links to different language variants */
                $s .= $this->variantLinks();
                $s .= $this->extensionTabLinks();
-
                if ( $wgUser->isAnon() ) {
-                       $s .= $sep . $this->specialLink( "userlogin" );
+                       $s .= $sep . $this->specialLink( 'userlogin' );
                } else {
+                       $name = $wgUser->getName();
+                       /* show user page and user talk links */
+                       $s .= $sep . $this->link( $wgUser->getUserPage(), wfMsgHtml( 'mypage' ) );
+                       $s .= $sep . $this->link( $wgUser->getTalkPage(), wfMsgHtml( 'mytalk' ) );
+                       if ( $wgUser->getNewtalk() ) {
+                               $s .= ' *';
+                       }
+                       /* show watchlist link */
+                       $s .= $sep . $this->specialLink( 'watchlist' );
+                       /* show my contributions link */
+                       $s .= $sep . $this->link(
+                               SpecialPage::getSafeTitleFor( "Contributions", $wgUser->getName() ),
+                               wfMsgHtml( 'mycontris' ) );
+                       /* show my preferences link */
+                       $s .= $sep . $this->specialLink( 'preferences' );
+                       /* show upload file link */
                        if ( $wgEnableUploads ) {
-                               $s .= $sep . $this->specialLink( "upload" );
+                               $s .= $sep . $this->specialLink( 'upload' );
                        }
-                       $s .= $sep . $this->specialLink( "userlogout" );
+                       /* show log out link */
+                       $s .= $sep . $this->specialLink( 'userlogout' );
                }
 
                $s .= $sep . $this->specialPagesList();