phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] CVS: phpgwapi/inc class.contacts.inc.php,1.12,1.13


From: Miles Lott <address@hidden>
Subject: [Phpgroupware-cvs] CVS: phpgwapi/inc class.contacts.inc.php,1.12,1.13
Date: Sun, 26 May 2002 21:32:08 -0400

Update of /cvsroot/phpgroupware/phpgwapi/inc
In directory subversions:/tmp/cvs-serv11386

Modified Files:
        class.contacts.inc.php 
Log Message:
This should allow for another app to load its own contacts class as a 
replacement
for the api version.  If the app wants to include the api shared class, it 
should
do so manually.



Index: class.contacts.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/inc/class.contacts.inc.php,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -r1.12 -r1.13
*** class.contacts.inc.php      5 Jul 2001 07:37:36 -0000       1.12
--- class.contacts.inc.php      27 May 2002 01:32:04 -0000      1.13
***************
*** 1,8 ****
  <?php
!       if (!$phpgw_info['server']['contact_repository'])
        {
!               $phpgw_info['server']['contact_repository'] = 'sql';
        }
!       include(PHPGW_API_INC . 
'/class.contacts_'.$phpgw_info['server']['contact_repository'] . '.inc.php');
!       include(PHPGW_API_INC . '/class.contacts_shared.inc.php');
  ?>
--- 1,32 ----
  <?php
!       if(!$GLOBALS['phpgw_info']['server']['contact_repository'])
        {
!               $GLOBALS['phpgw_info']['server']['contact_repository'] = 'sql';
        }
!       if(!$GLOBALS['phpgw_info']['server']['contact_application'] ||
!               $GLOBALS['phpgw_info']['server']['contact_application'] == 
'addressbook')
!       {
!               $contactapp = 'phpgwapi';
!       }
!       else
!       {
!               $contactapp = 
$GLOBALS['phpgw_info']['server']['contact_application'];
!       }
! 
!       $repository = PHPGW_SERVER_ROOT . '/' . $contactapp
!               . '/inc/class.contacts_' . 
$GLOBALS['phpgw_info']['server']['contact_repository'] . '.inc.php';
!       $shared     = PHPGW_SERVER_ROOT . '/' . $contactapp . 
'/inc/class.contacts_shared.inc.php';
! 
!       if(@file_exists($repository))
!       {
!               include($repository);
!       }
!       if(@file_exists($shared))
!       {
!               include($shared);
!       }
! 
!       unset($contactapp);
!       unset($repository);
!       unset($shared);
  ?>




reply via email to

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