phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] phpgwapi/inc class.common.inc.php


From: Dave Hall
Subject: [Phpgroupware-cvs] phpgwapi/inc class.common.inc.php
Date: Sun, 01 Oct 2006 12:02:13 +0000

CVSROOT:        /cvsroot/phpgwapi
Module name:    phpgwapi
Changes by:     Dave Hall <skwashd>     06/10/01 12:02:13

Modified files:
        inc            : class.common.inc.php 

Log message:
        notices and mergs my version to cvs to avoid more conflicts

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.common.inc.php?cvsroot=phpgwapi&r1=1.245&r2=1.246

Patches:
Index: class.common.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.common.inc.php,v
retrieving revision 1.245
retrieving revision 1.246
diff -u -b -r1.245 -r1.246
--- class.common.inc.php        25 Sep 2006 14:12:28 -0000      1.245
+++ class.common.inc.php        1 Oct 2006 12:02:13 -0000       1.246
@@ -8,7 +8,7 @@
        * @license http://www.gnu.org/licenses/lgpl.html GNU Lesser General 
Public License
        * @package phpgwapi
        * @subpackage utilities
-       * @version $Id: class.common.inc.php,v 1.245 2006/09/25 14:12:28 Caeies 
Exp $
+       * @version $Id: class.common.inc.php,v 1.246 2006/10/01 12:02:13 
skwashd Exp $
        */
 
        /**
@@ -379,8 +379,8 @@
                        if (! $lid && ! $firstname && ! $lastname)
                        {
                                $lid       = 
isset($GLOBALS['phpgw_info']['user']['account_lid'])       ? 
$GLOBALS['phpgw_info']['user']['account_lid'] : '';
-                               $firstname = 
isset($GLOBALS['phpgw_info']['user']['firstname'])         ? 
$GLOBALS['phpgw_info']['user']['firstname']   : '';
-                               $lastname  = 
isset($GLOBALS['phpgw_info']['user']['lastname'])          ? 
$GLOBALS['phpgw_info']['user']['lastname']    : '';
+                               $firstname = 
isset($GLOBALS['phpgw_info']['user']['account_firstname']) ? 
$GLOBALS['phpgw_info']['user']['account_firstname']   : '';
+                               $lastname  = 
isset($GLOBALS['phpgw_info']['user']['account_lastname']) ? 
$GLOBALS['phpgw_info']['user']['account_lastname']     : '';
                        }
 
                        $display = 'firstname';
@@ -391,7 +391,7 @@
 
                        if (!$firstname && !$lastname || $display == 'username')
                        {
-                               return $lid;
+                               return ''; //$lid;
                        }
                        if ($lastname)
                        {
@@ -407,23 +407,13 @@
                        switch($display)
                        {
                                case 'all':
-                                       if ($lid)
-                                       {
-                                               $name = '['.$lid.'] ';
-                                       }
-                                       // fall-through
                                case 'lastname':
                                        $name .= implode(', ',$a);
                                        break;
                                case 'firstall':
-                                       if ($lid) 
-                                       {
-                                               $name = ' ['.$lid.']';
-                                       }
-                                       // fall-through
                                case 'firstname':
                                default:
-                                       $name = $firstname . ' ' . $lastname . 
$name;
+                                       $name = $firstname . ' ' . $lastname;
                        }
                        return $name;
                }
@@ -1008,7 +998,9 @@
                        $GLOBALS['phpgw_info']['navbar']['home']['icon_hover']  
= $this->image_on('phpgwapi',Array('home','nonav'),'-over');
 
                        list($first) = 
each($GLOBALS['phpgw_info']['user']['apps']);
-                       
if(isset($GLOBALS['phpgw_info']['user']['apps']['admin']) && 
is_array($GLOBALS['phpgw_info']['user']['apps']['admin']) && $first != 'admin')
+                       if ( 
isset($GLOBALS['phpgw_info']['user']['apps']['admin'])
+                               && 
is_array($GLOBALS['phpgw_info']['user']['apps']['admin']) 
+                               && $first != 'admin')
                        {
                                $newarray['admin'] = 
$GLOBALS['phpgw_info']['user']['apps']['admin'];
                                foreach($GLOBALS['phpgw_info']['user']['apps'] 
as $index => $value)
@@ -1065,7 +1057,8 @@
                                $app_title = 
$GLOBALS['phpgw_info']['apps'][$app]['title'];
                        }
 
-                       if 
(isset($GLOBALS['phpgw_info']['user']['apps']['preferences']) && 
$GLOBALS['phpgw_info']['user']['apps']['preferences'])      // preferences last
+                       if 
(isset($GLOBALS['phpgw_info']['user']['apps']['preferences']) 
+                               && 
$GLOBALS['phpgw_info']['user']['apps']['preferences'])       // preferences last
                        {
                                $prefs = 
$GLOBALS['phpgw_info']['navbar']['preferences'];
                                
unset($GLOBALS['phpgw_info']['navbar']['preferences']);
@@ -1164,7 +1157,8 @@
                        if ( isset($GLOBALS['phpgw_info']['menuaction']) )
                        {
                                list($app,$class,$method) = 
explode('.',$GLOBALS['phpgw_info']['menuaction']);
-                               if(is_array($GLOBALS[$class]->public_functions) 
+                               if ( isset($GLOBALS[$class]->public_functions)
+                                       && 
is_array($GLOBALS[$class]->public_functions) 
                                && 
isset($GLOBALS[$class]->public_functions['css']) )
                                {
                                        $app_css .= $GLOBALS[$class]->css();
@@ -1210,7 +1204,8 @@
                        if ( isset($GLOBALS['phpgw_info']['menuaction']) )
                        {
                                list($app, $class, $method) = 
explode('.',$GLOBALS['phpgw_info']['menuaction']);
-                               if ( 
is_array($GLOBALS[$class]->public_functions) 
+                               if ( isset($GLOBALS[$class]->public_functions) 
+                                       && 
is_array($GLOBALS[$class]->public_functions) 
                                        && 
isset($GLOBALS[$class]->public_functions['java_script'])
                                        && 
$GLOBALS[$class]->public_functions['java_script'] )
                                {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]