array( array( 'text' => Title::newFromText( wfMsgForContent( 'mainpage' ) ), 'href' => Title::newFromText( wfMsgForContent( 'mainpage' ) )->getFullURL(), 'id' => 'n-mainpage', 'active' => '' ), array( 'text' => 'Random Page', 'href' => Title::newFromText( wfMsgForContent( 'randompage-url' ) )->getFullURL(), 'id' => 'n-randompage', 'active' => '' ) ) ); //add Community Portal, Recent Changes, Help to the navigation bar if the user is logged it. if ($wgUser->isLoggedIn() ) { $bar['navigation'][] = array( 'text' => 'Community Portal', 'href' => Title::newFromText( wfMsgForContent( 'portal-url' ) )->getFullURL(), 'id' => 'n-portal', 'active' => '' ); $bar['navigation'][] = array( 'text' => 'Current Events', 'href' => Title::newFromText( wfMsgForContent( 'currentevents-url' ) )->getFullURL(), 'id' => 'n-currentevents', 'active' => '' ); $bar['navigation'][] = array( 'text' => 'Recent Changes', 'href' => Title::newFromText( wfMsgForContent( 'recentchanges-url' ) )->getFullURL(), 'id' => 'n-recentchanges', 'active' => '', ); $bar['navigation'][] = array( 'text' => 'Help', 'href' => Title::newFromText( wfMsgForContent( 'helppage' ) )->getFullURL(), 'id' => 'n-help', 'active' => '' ); } return true; }