phpgroupware-cvs
[Top][All Lists]
Advanced

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

[Phpgroupware-cvs] CVS: phpgwapi/templates/verdilak head.inc.php,1.12.4


From: Ralf Becker <address@hidden>
Subject: [Phpgroupware-cvs] CVS: phpgwapi/templates/verdilak head.inc.php,1.12.4.1,1.12.4.2 navbar.inc.php,1.27.2.6,1.27.2.6.2.1navbar.tpl,1.12.2.1,1.12.2.1.2.1
Date: Fri, 28 Mar 2003 10:08:24 -0500

Update of /cvsroot/phpgroupware/phpgwapi/templates/verdilak
In directory subversions:/tmp/cvs-serv10113/templates/verdilak

Modified Files:
      Tag: Version-0_9_16-branch
        head.inc.php navbar.inc.php navbar.tpl 
Log Message:
now admin can enable/disable the preferences as any other app, fix for bug#2967


Index: head.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/templates/verdilak/Attic/head.inc.php,v
retrieving revision 1.12.4.1
retrieving revision 1.12.4.2
diff -C2 -r1.12.4.1 -r1.12.4.2
*** head.inc.php        28 Mar 2003 06:08:33 -0000      1.12.4.1
--- head.inc.php        28 Mar 2003 15:08:22 -0000      1.12.4.2
***************
*** 32,36 ****
  
  
!       $app = (isset($GLOBALS['phpgw_info']['flags']['currentapp']) ? ' [' . 
lang($GLOBALS['phpgw_info']['flags']['currentapp']) .']' : '');
  
        $tpl = CreateObject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);
--- 32,36 ----
  
  
!       $app = (isset($GLOBALS['phpgw_info']['flags']['currentapp']) ? ' [' . 
$GLOBALS['phpgw_info']['apps'][$GLOBALS['phpgw_info']['flags']['currentapp']]['title']
 .']' : '');
  
        $tpl = CreateObject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);

Index: navbar.inc.php
===================================================================
RCS file: 
/cvsroot/phpgroupware/phpgwapi/templates/verdilak/Attic/navbar.inc.php,v
retrieving revision 1.27.2.6
retrieving revision 1.27.2.6.2.1
diff -C2 -r1.27.2.6 -r1.27.2.6.2.1
*** navbar.inc.php      22 Mar 2003 12:07:51 -0000      1.27.2.6
--- navbar.inc.php      28 Mar 2003 15:08:22 -0000      1.27.2.6.2.1
***************
*** 18,24 ****
                $tpl->set_file(
                        array(
!                               'navbar' => 'navbar.tpl'
                        )
                );
  
                $var['img_root'] = 
$GLOBALS['phpgw_info']['server']['webserver_url'] . 
'/phpgwapi/templates/verdilak/images';
--- 18,26 ----
                $tpl->set_file(
                        array(
!                               'navbartpl' => 'navbar.tpl'
                        )
                );
+               $tpl->set_block('navbartpl','preferences');
+               $tpl->set_block('navbartpl','navbar');
  
                $var['img_root'] = 
$GLOBALS['phpgw_info']['server']['webserver_url'] . 
'/phpgwapi/templates/verdilak/images';
***************
*** 26,44 ****
                $var['navbar_text'] = 
$GLOBALS['phpgw_info']['theme']['navbar_text'];
                $applications = '';
!               while ($app = each($GLOBALS['phpgw_info']['navbar']))
                {
!                       if ($app[1]['title'] != 'Home' && $app[1]['title'] != 
'preferences' && ! ereg('About',$app[1]['title']) && $app[1]['title'] != 
'Logout')
                        {
                                if 
($GLOBALS['phpgw_info']['user']['preferences']['common']['navbar_format'] != 
'text')
                                {
!                                       $title = '<img src="' . $app[1]['icon'] 
. '" alt="' . $app[1]['title'] . '" title="'
!                                               . $app[1]['title'] . '" 
border="0">';
                                }
  
                                if 
($GLOBALS['phpgw_info']['user']['preferences']['common']['navbar_format'] != 
'icons')
                                {
!                                       $title .= '<br>' . $app[1]['title'];
                                }
!                               $applications .= '<br><a href="' . 
$app[1]['url'] . '"';
                                if 
(isset($GLOBALS['phpgw_info']['flags']['navbar_target']) &&
                                    
$GLOBALS['phpgw_info']['flags']['navbar_target'])
--- 28,46 ----
                $var['navbar_text'] = 
$GLOBALS['phpgw_info']['theme']['navbar_text'];
                $applications = '';
!               foreach($GLOBALS['phpgw_info']['navbar'] as $app => $app_data)
                {
!                       if ($app != 'home' && $app != 'preferences' && ! 
ereg('about',$app) && $app != 'logout')
                        {
                                if 
($GLOBALS['phpgw_info']['user']['preferences']['common']['navbar_format'] != 
'text')
                                {
!                                       $title = '<img src="' . 
$app_data['icon'] . '" alt="' . $app_data['title'] . '" title="'
!                                               . $app_data['title'] . '" 
border="0">';
                                }
  
                                if 
($GLOBALS['phpgw_info']['user']['preferences']['common']['navbar_format'] != 
'icons')
                                {
!                                       $title .= '<br>' . $app_data['title'];
                                }
!                               $applications .= '<br><a href="' . 
$app_data['url'] . '"';
                                if 
(isset($GLOBALS['phpgw_info']['flags']['navbar_target']) &&
                                    
$GLOBALS['phpgw_info']['flags']['navbar_target'])
***************
*** 119,122 ****
--- 121,133 ----
                }
                $tpl->set_var($var);
+               // check if user is allowed to change his prefs
+               if ($GLOBALS['phpgw_info']['user']['apps']['preferences'])
+               {
+                       $tpl->parse('preferences_icon','preferences');
+               }
+               else
+               {
+                       $tpl->set_var('preferences_icon','');
+               }
                $tpl->pfp('out','navbar');
                // If the application has a header include, we now include it

Index: navbar.tpl
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/templates/verdilak/Attic/navbar.tpl,v
retrieving revision 1.12.2.1
retrieving revision 1.12.2.1.2.1
diff -C2 -r1.12.2.1 -r1.12.2.1.2.1
*** navbar.tpl  10 Mar 2003 22:47:39 -0000      1.12.2.1
--- navbar.tpl  28 Mar 2003 15:08:22 -0000      1.12.2.1.2.1
***************
*** 1,33 ****
! 
! <!-- BEGIN navbar -->
! 
! <table border="0" cellspacing="0" cellpadding="0" width="100%" 
bgcolor="{table_bg_color}">
! <tr background="{img_root}/bg_filler.gif">
! <td background="{img_root}/bg_filler.gif" align="left" valign="bottom"><a 
href="http://www.phpgroupware.org"; target="_new"><img src="{img_root}/{logo}" 
border="0" alt="phpGroupWare"></a></td>
! <td background="{img_root}/bg_filler.gif" align="center" valign="bottom" 
width="100%"><font color="{navbar_text}" size="-1">{user_info}</font></td>
! <td background="{img_root}/bg_filler.gif" align="right" valign="bottom" 
rowspan="2" nowrap><a href="{home_link}"><img src="{welcome_img}" border="0" 
alt="Welcome"></a><a href="{preferences_link}"><img src="{preferences_img}" 
border="0" alt="Preferences"></a><a href="{logout_link}"><img 
src="{logout_img}" border="0" alt="Logout"></a><a href="{help_link}"><img 
src="{img_root}/help.gif" border="0" alt="Help"></a></td></tr>
! <tr background="{img_root}/bg_filler.gif">
! <td align="center" width="100%" valign="bottom" colspan="2"><img 
src="{img_root}/greybar.jpg" height="6"  width="100%" alt="bar"></td></tr>
! </table>
! 
! <table border="0" cellspacing="0" cellpadding="0" width="100%">
!  <tr valign="top">
!   <td background="{img_root}/navbar_filler.jpg" align="left">
!    {applications}
!   </td>
!   <td width="100%">
!    <table border="0" cellspacing="1" cellpadding="1" width="100%">
!     <tr>
!      <td align="left">
!       {current_users}
!      </td>
!      <td align="right">
!       <font style="font-family: Geneva,Arial,Helvetica,sans-serif; font-size: 
12pt;">{powered_by}</font>
!      </td>
!     </tr>
!    </table>
!    <table border="0" cellpadding="5" width="100%">
!     <tr>
!      <td>
! <center>{messages}</center>
! <!-- END navbar -->
--- 1,36 ----
! 
! <!-- BEGIN navbar -->
! 
! <table border="0" cellspacing="0" cellpadding="0" width="100%" 
bgcolor="{table_bg_color}">
! <tr background="{img_root}/bg_filler.gif">
! <td background="{img_root}/bg_filler.gif" align="left" valign="bottom"><a 
href="http://www.phpgroupware.org"; target="_new"><img src="{img_root}/{logo}" 
border="0" alt="phpGroupWare"></a></td>
! <td background="{img_root}/bg_filler.gif" align="center" valign="bottom" 
width="100%"><font color="{navbar_text}" size="-1">{user_info}</font></td>
! <td background="{img_root}/bg_filler.gif" align="right" valign="bottom" 
rowspan="2" nowrap><a href="{home_link}"><img src="{welcome_img}" border="0" 
alt="Welcome"></a>{preferences_icon}<a href="{logout_link}"><img 
src="{logout_img}" border="0" alt="Logout"></a><a href="{help_link}"><img 
src="{img_root}/help.gif" border="0" alt="Help"></a></td></tr>
! <tr background="{img_root}/bg_filler.gif">
! <td align="center" width="100%" valign="bottom" colspan="2"><img 
src="{img_root}/greybar.jpg" height="6"  width="100%" alt="bar"></td></tr>
! </table>
! 
! <table border="0" cellspacing="0" cellpadding="0" width="100%">
!  <tr valign="top">
!   <td background="{img_root}/navbar_filler.jpg" align="left">
!    {applications}
!   </td>
!   <td width="100%">
!    <table border="0" cellspacing="1" cellpadding="1" width="100%">
!     <tr>
!      <td align="left">
!       {current_users}
!      </td>
!      <td align="right">
!       <font style="font-family: Geneva,Arial,Helvetica,sans-serif; font-size: 
12pt;">{powered_by}</font>
!      </td>
!     </tr>
!    </table>
!    <table border="0" cellpadding="5" width="100%">
!     <tr>
!      <td>
! <center>{messages}</center>
! <!-- END navbar -->
! 
! <!-- BEGIN preferences --><a href="{preferences_link}"><img 
src="{preferences_img}" border="0" alt="Preferences"></a>
! <!-- END preferences -->





reply via email to

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