forked from extern/egroupware
updated idsociety to new format. works fine for me in normal/tables and frames mode
This commit is contained in:
parent
9bd5ee2de5
commit
e1cdcafb61
@ -715,6 +715,14 @@
|
||||
$GLOBALS['phpgw_info']['server']['template_set'] = 'default';
|
||||
}
|
||||
|
||||
/******** start temporarily code **************************************/
|
||||
/* this just makes sure the template set is updated to the new format */
|
||||
if (!@is_file(PHPGW_SERVER_ROOT . '/phpgwapi/templates/' . $GLOBALS['phpgw_info']['server']['template_set'].'/parts.inc.php'))
|
||||
{
|
||||
$GLOBALS['phpgw_info']['server']['template_set'] = 'default';
|
||||
}
|
||||
/******** end temporarily code **************************************/
|
||||
|
||||
$tpldir = PHPGW_SERVER_ROOT . '/' . $appname . '/templates/' . $GLOBALS['phpgw_info']['server']['template_set'];
|
||||
$tpldir_default = PHPGW_SERVER_ROOT . '/' . $appname . '/templates/default';
|
||||
|
||||
@ -1275,7 +1283,7 @@
|
||||
|
||||
function load_preload_images_data()
|
||||
{
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw_info']['navbar']['logout']['icon'];
|
||||
//$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw_info']['navbar']['logout']['icon'];
|
||||
|
||||
if(@is_array($GLOBALS['phpgw_info']['flags']['preload_images']))
|
||||
{
|
||||
@ -1300,6 +1308,11 @@
|
||||
|
||||
function load_phpgw_body_tags()
|
||||
{
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['bgcolor'] = $GLOBALS['phpgw_info']['theme']['bg_color'];
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['alink'] = $GLOBALS['phpgw_info']['theme']['alink'];
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['link'] = $GLOBALS['phpgw_info']['theme']['link'];
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['vlink'] = $GLOBALS['phpgw_info']['theme']['vlink'];
|
||||
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['marginwidth']='0';
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['marginheight']='0';
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['topmargin']='0';
|
||||
@ -1318,7 +1331,10 @@
|
||||
reset($GLOBALS['phpgw_info']['flags']['body_tags']);
|
||||
while(list($key,$value) = each($GLOBALS['phpgw_info']['flags']['body_tags']))
|
||||
{
|
||||
$body_tags_string .= " $key=\"$value\"";
|
||||
if($value != '')
|
||||
{
|
||||
$body_tags_string .= " $key=\"$value\"";
|
||||
}
|
||||
}
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_body_tags',$body_tags_string);
|
||||
}
|
||||
|
@ -325,9 +325,6 @@
|
||||
$GLOBALS['phpgw_info']['flags']['msgbox_data'][$message]=False;
|
||||
}
|
||||
|
||||
|
||||
/*DELETE ME SOON!!!!*/ $GLOBALS['phpgw_info']['user']['preferences']['common']['template_set'] = 'default';
|
||||
|
||||
/*************************************************************************\
|
||||
* A few hacker resistant constants that will be used throught the program *
|
||||
\*************************************************************************/
|
||||
@ -352,16 +349,16 @@
|
||||
/* These default values will be overridden and appended to as needed by template sets */
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_top_table_height','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_top_frame_height','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_top_scrolling','NO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_top_scrolling','AUTO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_left_table_width','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_left_frame_width','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_left_scrolling','NO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_left_scrolling','AUTO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_right_table_width','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_right_frame_width','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_right_scrolling','NO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_right_scrolling','AUTO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_bottom_table_height','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_bottom_frame_height','0');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_bottom_scrolling','NO');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_bottom_scrolling','AUTO');
|
||||
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_head_charset',lang('charset'));
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_head_description','phpGroupWare');
|
||||
@ -562,6 +559,11 @@
|
||||
\*************************************************************************/
|
||||
if(!PHPGW_USE_FRAMES || PHPGW_FRAME_PART == 'body')
|
||||
{
|
||||
/* parse_bodypart() should not output anything. This is here for them to set body tags and such */
|
||||
if(function_exists('parse_bodypart'))
|
||||
{
|
||||
parse_bodypart();
|
||||
}
|
||||
/* Verify that user has rights to the currentapp */
|
||||
$continue_app_data = True;
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'home' &&
|
||||
|
@ -105,7 +105,7 @@
|
||||
$GLOBALS['phpgw']->template->set_file('parts','parts.tpl');
|
||||
$GLOBALS['phpgw']->template->set_block('parts','bottom_part');
|
||||
$var = Array(
|
||||
'msg' => "<p><p>\n".lang('Powered by phpGroupWare version x',$GLOBALS['phpgw_info']['server']['versions']['phpgwapi']),
|
||||
'msg' => "<p><p>\n".lang('Powered by phpGroupWare version x',$GLOBALS['phpgw_info']['server']['versions']['phpgwapi']).'<p>',
|
||||
'version' => $GLOBALS['phpgw_info']['server']['versions']['phpgwapi']
|
||||
);
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
|
@ -17,7 +17,7 @@
|
||||
<!-- BEGIN bottom_part -->
|
||||
<TABLE border="0" cellspacing="0" cellpadding="0" width="100%" bgcolor="{navbar_bg}">
|
||||
<TR>
|
||||
<TD align="CENTER">{msg}<BR></TD>
|
||||
<TD align="CENTER">{msg}<BR></TD>
|
||||
</TR>
|
||||
</Table>
|
||||
<!-- END bottom_part -->
|
||||
|
@ -1,17 +0,0 @@
|
||||
<!-- BEGIN footer -->
|
||||
<br>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<!-- BEGIN B_powered_bottom -->
|
||||
<table border="0" cellspacing="0" cellpadding="0" width="100%">
|
||||
<tr>
|
||||
<td align="center" background="{em_bottom_img}">
|
||||
<font color="{power_textcolor}">{powered}</font>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<!-- END B_powered_bottom -->
|
||||
</BODY>
|
||||
<!-- END footer -->
|
||||
</HTML>
|
@ -1,45 +0,0 @@
|
||||
<?php
|
||||
/**************************************************************************\
|
||||
* phpGroupWare *
|
||||
* http://www.phpgroupware.org *
|
||||
* -------------------------------------------- *
|
||||
* This program is free software; you can redistribute it and/or modify it *
|
||||
* under the terms of the GNU General Public License as published by the *
|
||||
* Free Software Foundation; either version 2 of the License, or (at your *
|
||||
* option) any later version. *
|
||||
\**************************************************************************/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
$app_css = '';
|
||||
if(@isset($GLOBALS['HTTP_GET_VARS']['menuaction']))
|
||||
{
|
||||
list($app,$class,$method) = explode('.',$GLOBALS['HTTP_GET_VARS']['menuaction']);
|
||||
if(is_array($GLOBALS[$class]->public_functions) && $GLOBALS[$class]->public_functions['css'])
|
||||
{
|
||||
$app_css = $GLOBALS[$class]->css();
|
||||
}
|
||||
}
|
||||
|
||||
$bodyheader = 'bgcolor="'.$GLOBALS['phpgw_info']['theme']['bg_color'].'" alink="'.$GLOBALS['phpgw_info']['theme']['alink'].'" link="'.$GLOBALS['phpgw_info']['theme']['link'].'" vlink="'.$GLOBALS['phpgw_info']['theme']['vlink'].'"';
|
||||
if (!$GLOBALS['phpgw_info']['server']['htmlcompliant'])
|
||||
{
|
||||
$bodyheader .= ' topmargin="0" marginheight="0" marginwidth="0" leftmargin="0"';
|
||||
}
|
||||
|
||||
$tpl = CreateObject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);
|
||||
$tpl->set_unknowns('remove');
|
||||
$tpl->set_file(array('head' => 'head.tpl'));
|
||||
$var = Array (
|
||||
'img_icon' => PHPGW_IMAGES_DIR . '/favicon.ico',
|
||||
'img_shortcut' => PHPGW_IMAGES_DIR . '/favicon.ico',
|
||||
'charset' => lang('charset'),
|
||||
'font_family' => $GLOBALS['phpgw_info']['theme']['font'],
|
||||
'website_title' => $GLOBALS['phpgw_info']['server']['site_title'],
|
||||
'body_tags' => $bodyheader,
|
||||
'app_css' => $app_css
|
||||
);
|
||||
$tpl->set_var($var);
|
||||
$tpl->pfp('out','head');
|
||||
unset($tpl);
|
||||
?>
|
@ -1,35 +0,0 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<!-- BEGIN head -->
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<META http-equiv="Content-Type" content="text/html; charset={charset}">
|
||||
<META name="AUTHOR" content="phpGroupWare http://www.phpgroupware.org">
|
||||
<META NAME="description" CONTENT="phpGroupWare">
|
||||
<META NAME="keywords" CONTENT="phpGroupWare">
|
||||
<META NAME="robots" content="none">
|
||||
<LINK REL="ICON" href="{img_icon}" type="image/x-ico">
|
||||
<LINK REL="SHORTCUT ICON" href="{img_shortcut}">
|
||||
<STYLE type="text/css">{phpgw_css}</STYLE>
|
||||
<SCRIPT language="JavaScript">
|
||||
<!--
|
||||
function MM_preloadImages()
|
||||
{
|
||||
if (document.images)
|
||||
{
|
||||
var imgFiles = MM_preloadImages.arguments;
|
||||
if (document.preloadArray==null) document.preloadArray = new Array();
|
||||
var i = document.preloadArray.length;
|
||||
with (document) for (var j=0; j<imgFiles.length; j++) if (imgFiles[j].charAt(0)!="#")
|
||||
{
|
||||
preloadArray[i] = new Image;
|
||||
preloadArray[i++].src = imgFiles[j];
|
||||
}
|
||||
}
|
||||
}
|
||||
//-->
|
||||
</SCRIPT>
|
||||
|
||||
<TITLE>{website_title}</TITLE>
|
||||
</HEAD>
|
||||
<!-- idsociety body tags continue into navbar.tpl, so the closing bracket here is there END Head -->
|
||||
<BODY {body_tags}
|
@ -1,67 +0,0 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
||||
<meta name="AUTHOR" content="phpGroupWare http://www.phpgroupware.org">
|
||||
<meta name="description" content="phpGroupWare">
|
||||
<meta name="keywords" content="phpGroupWare login screen">
|
||||
<style type="text/css">
|
||||
a { text-decoration:none; }
|
||||
A:link{ text-decoration:none; color: #336699; }
|
||||
A:visted{ text-decoration:none; color: #336699; }
|
||||
A:active{ text-decoration:none; color: #ff0000; }
|
||||
A:hover{ text-decoration:none; color: #cc0000; }
|
||||
td {text-decoration:none; color: #ffffff; }
|
||||
body { margin-top: 0px; margin-right: 0px; margin-left: 0px; font-family: "Arial, Helvetica, san-serif" }
|
||||
.tablink { color: #000000; }
|
||||
</style>
|
||||
<title>{website_title} - Login</title>
|
||||
</head>
|
||||
<!-- idsociety body tags continue into navbar.tpl, so the closing bracket here is there END Head -->
|
||||
<body bgcolor="#cccccc" alink="#ff0000" link="#336699" vlink="#336699">
|
||||
|
||||
<a href="http://www.phpgroupware.org"><img src="phpgwapi/templates/{template_set}/images/logo.gif" alt="phpGroupWare" border="0"></a>
|
||||
<p> </p>
|
||||
<center>{lang_message}</center>
|
||||
<p> </p>
|
||||
|
||||
<table border="0" align="center" width="40%" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td>
|
||||
<table border="0" width="100%" cellpadding="2" cellspacing="1">
|
||||
<tr bgcolor="#525252">
|
||||
<td align="left" valign="middle"> phpGroupWare</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="baseline">
|
||||
<form name="login" method="post" action="{login_url}">
|
||||
<input type="hidden" name="passwd_type" value="text">
|
||||
<table bgcolor="#adadad" border="0" align="center" width="100%" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="2" align="center">{cd}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">{lang_username}: </td>
|
||||
<td><input name="login" value="{cookie}"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">{lang_password}: </td>
|
||||
<td><input name="passwd" type="password"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="center"><input type="submit" value="{lang_login}" name="submitit"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="right">{version}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</FORM>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<!-- END login_form -->
|
||||
</html>
|
@ -1,14 +0,0 @@
|
||||
|
||||
<!-- BEGIN form -->
|
||||
<BODY bgcolor="#FFFFFF">
|
||||
<A href="http://www.phpgroupware.org"><img src="phpGroupWare.jpg" alt="phpGroupWare" border="0"></a>
|
||||
|
||||
<TABLE border="0" height="94%" width="100%">
|
||||
<TR>
|
||||
<TD align="CENTER">
|
||||
Opps! You caught us in the middle of a system upgrade.<br>Please, check back with us shortly.
|
||||
</TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
|
||||
<!-- END form -->
|
@ -1,74 +0,0 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
||||
<meta name="AUTHOR" content="phpGroupWare http://www.phpgroupware.org">
|
||||
<meta name="description" content="phpGroupWare">
|
||||
<meta name="keywords" content="phpGroupWare login screen">
|
||||
<style type="text/css">
|
||||
a { text-decoration:none; }
|
||||
A:link{ text-decoration:none; color: #336699; }
|
||||
A:visted{ text-decoration:none; color: #336699; }
|
||||
A:active{ text-decoration:none; color: #ff0000; }
|
||||
A:hover{ text-decoration:none; color: #cc0000; }
|
||||
td {text-decoration:none; color: #ffffff; }
|
||||
body { margin-top: 0px; margin-right: 0px; margin-left: 0px; font-family: "Arial, Helvetica, san-serif" }
|
||||
.tablink { color: #000000; }
|
||||
</style>
|
||||
<title>{website_title} - Login</title>
|
||||
</head>
|
||||
<!-- idsociety body tags continue into navbar.tpl, so the closing bracket here is there END Head -->
|
||||
<body bgcolor="#cccccc" alink="#ff0000" link="#336699" vlink="#336699">
|
||||
|
||||
<a href="http://www.phpgroupware.org"><img src="phpgwapi/templates/{template_set}/images/logo.gif" alt="phpGroupWare" border="0"></a>
|
||||
<p> </p>
|
||||
<center>{lang_message}</center>
|
||||
<p> </p>
|
||||
|
||||
<table border="0" align="center" width="40%" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td>
|
||||
<table border="0" width="100%" cellpadding="2" cellspacing="1">
|
||||
<tr bgcolor="#525252">
|
||||
<td align="left" valign="middle"> phpGroupWare</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="baseline">
|
||||
<form method="post" action="{login_url}">
|
||||
<table border="0" align="CENTER" bgcolor="#adadad" width="100%" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="3" align="CENTER">
|
||||
{cd}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="RIGHT"><font color="#000000">{lang_username}:</font></td>
|
||||
<td align="RIGHT"><input name="login" value="{cookie}"></td>
|
||||
<td align="LEFT"> <select name="logindomain">{select_domain}</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="RIGHT"><font color="#000000">{lang_password}:</font></td>
|
||||
<td align="RIGHT"><input name="passwd" type="password" onChange="this.form.submit()"></td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3" align="CENTER">
|
||||
<input type="submit" value="{lang_login}" name="submitit">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3" align="RIGHT">
|
||||
<font color="#000000" size="-1">{version}</font>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<!-- END login_form -->
|
||||
</html>
|
@ -1 +0,0 @@
|
||||
<td align="center" width="{width}">{value}</td>
|
@ -9,22 +9,20 @@
|
||||
* option) any later version. *
|
||||
\**************************************************************************/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
function parse_navbar($force = False)
|
||||
{
|
||||
$tpl = CreateObject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);
|
||||
$tpl->set_unknowns('remove');
|
||||
|
||||
$tpl->set_file(
|
||||
array(
|
||||
'navbar' => 'navbar.tpl'
|
||||
)
|
||||
);
|
||||
|
||||
//$tpl->set_block('navbar','B_powered_top','V_powered_top');
|
||||
//$tpl->set_block('navbar','B_num_users','V_num_users');
|
||||
/* $Id$ */
|
||||
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_top_table_height','10%');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_top_frame_height','85');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_left_table_width','5%');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_left_frame_width','155');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_bottom_table_height','5%');
|
||||
$GLOBALS['phpgw']->template->set_var('phpgw_bottom_frame_height','30');
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['background']=$GLOBALS['phpgw']->common->image('phpgwapi','content_spacer_middle');
|
||||
|
||||
function parse_toppart($output)
|
||||
{
|
||||
$GLOBALS['phpgw']->template->set_file('parts','parts.tpl');
|
||||
$GLOBALS['phpgw']->template->set_block('parts','top_part');
|
||||
$var['img_root'] = PHPGW_IMAGES_DIR;
|
||||
$var['table_bg_color'] = $GLOBALS['phpgw_info']['theme']['navbar_bg'];
|
||||
|
||||
@ -50,7 +48,98 @@
|
||||
$strip_portion = $GLOBALS['phpgw_info']['server']['webserver_url'].'/';
|
||||
}
|
||||
|
||||
# echo '<pre>'; print_r($GLOBALS['phpgw_info']['navbar']); echo '</pre>';
|
||||
$var['home_link'] = $GLOBALS['phpgw_info']['navbar']['home']['url'];
|
||||
$var['preferences_link'] = $GLOBALS['phpgw_info']['navbar']['preferences']['url'];
|
||||
$var['logout_link'] = $GLOBALS['phpgw_info']['navbar']['logout']['url'];
|
||||
$var['help_link'] = $GLOBALS['phpgw_info']['navbar']['about']['url'];
|
||||
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'home')
|
||||
{
|
||||
$var['welcome_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','welcome2');
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw']->common->image_on('phpgwapi','welcome2','_over');
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['welcome_img'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','welcome2','_over');
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw']->common->image('phpgwapi','welcome2');
|
||||
}
|
||||
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'preferences')
|
||||
{
|
||||
$var['preferences_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','preferences2');
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw']->common->image_on('phpgwapi','preferences2','_over');
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['preferences_img'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','preferences2','_over');
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw']->common->image('phpgwapi','preferences2');
|
||||
}
|
||||
|
||||
$var['logout_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','log_out2');
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $GLOBALS['phpgw']->common->image_on('phpgwapi','log_out2','_over');
|
||||
|
||||
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'about')
|
||||
{
|
||||
$var['about_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','question_mark2');
|
||||
$var['about_img_hover'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','question_mark2','_over');
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['about_img'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','question_mark2','_over');
|
||||
$var['about_img_hover'] = $GLOBALS['phpgw']->common->image('phpgwapi','question_mark2');
|
||||
}
|
||||
|
||||
$var['em_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','em');
|
||||
$var['logo_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','logo2');
|
||||
$var['top_spacer_middle_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','top_spacer_middle');
|
||||
|
||||
// "powered_by_color" and "_size" are is also used by number of current users thing
|
||||
$var['powered_by_size'] = '2';
|
||||
$var['powered_by_color'] = '#ffffff';
|
||||
if ($GLOBALS['phpgw_info']['server']['showpoweredbyon'] == 'top')
|
||||
{
|
||||
$var['powered_by'] = lang('Powered by phpGroupWare version x',$GLOBALS['phpgw_info']['server']['versions']['phpgwapi']);
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['powered_by'] = '';
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
}
|
||||
|
||||
if (isset($GLOBALS['phpgw_info']['navbar']['admin']) && isset($GLOBALS['phpgw_info']['user']['preferences']['common']['show_currentusers']))
|
||||
{
|
||||
$db = $GLOBALS['phpgw']->db;
|
||||
$db->query('select count(session_id) from phpgw_sessions');
|
||||
$db->next_record();
|
||||
$var['current_users'] = '<a href="' . $GLOBALS['phpgw']->link('/index.php','menuaction=admin.uicurrentsessions.list_sessions')
|
||||
. '"> ' . lang('Current users') . ': ' . $db->f(0) . '</a>';
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['current_users'] = '';
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
}
|
||||
|
||||
$var['user_info_name'] = $GLOBALS['phpgw']->common->display_fullname();
|
||||
$now = time();
|
||||
$var['user_info_date'] =
|
||||
lang($GLOBALS['phpgw']->common->show_date($now,'l')) . ' '
|
||||
. $GLOBALS['phpgw']->common->show_date($now,$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
|
||||
$var['user_info'] = $var['user_info_name'] .' - ' .$var['user_info_date'];
|
||||
$var['user_info_size'] = '2';
|
||||
$var['user_info_color'] = '#000000';
|
||||
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
$GLOBALS['phpgw']->template->fp($output,'top_part');
|
||||
}
|
||||
|
||||
function parse_leftpart($output)
|
||||
{
|
||||
$GLOBALS['phpgw']->template->set_file('parts','parts.tpl');
|
||||
$GLOBALS['phpgw']->template->set_block('parts','left_part');
|
||||
$applications = '';
|
||||
while ($app = each($GLOBALS['phpgw_info']['navbar']))
|
||||
{
|
||||
@ -87,137 +176,27 @@
|
||||
{
|
||||
$img_src_over = str_replace($strip_portion,'',$img_src_over);
|
||||
}
|
||||
|
||||
$pre_load[] = $img_src_over;
|
||||
$GLOBALS['phpgw_info']['flags']['preload_images'][] = $img_src_over;
|
||||
}
|
||||
}
|
||||
|
||||
$var['app_images'] = implode("',\r\n'",$pre_load);
|
||||
|
||||
$var['applications'] = $applications;
|
||||
|
||||
$var['home_link'] = $GLOBALS['phpgw_info']['navbar']['home']['url'];
|
||||
$var['preferences_link'] = $GLOBALS['phpgw_info']['navbar']['preferences']['url'];
|
||||
$var['logout_link'] = $GLOBALS['phpgw_info']['navbar']['logout']['url'];
|
||||
$var['help_link'] = $GLOBALS['phpgw_info']['navbar']['about']['url'];
|
||||
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'home')
|
||||
{
|
||||
$var['welcome_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','welcome2');
|
||||
$var['welcome_img_hover'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','welcome2','_over');
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['welcome_img'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','welcome2','_over');
|
||||
$var['welcome_img_hover'] = $GLOBALS['phpgw']->common->image('phpgwapi','welcome2');
|
||||
}
|
||||
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'preferences')
|
||||
{
|
||||
$var['preferences_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','preferences2');
|
||||
$var['preferences_img_hover'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','preferences2','_over');
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['preferences_img'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','preferences2','_over');
|
||||
$var['preferences_img_hover'] = $GLOBALS['phpgw']->common->image('phpgwapi','preferences2');
|
||||
}
|
||||
|
||||
$var['logout_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','log_out2');
|
||||
$var['logout_img_hover'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','log_out2','_over');
|
||||
|
||||
if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'about')
|
||||
{
|
||||
$var['about_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','question_mark2');
|
||||
$var['about_img_hover'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','question_mark2','_over');
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['about_img'] = $GLOBALS['phpgw']->common->image_on('phpgwapi','question_mark2','_over');
|
||||
$var['about_img_hover'] = $GLOBALS['phpgw']->common->image('phpgwapi','question_mark2');
|
||||
}
|
||||
|
||||
$var['content_spacer_middle_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','content_spacer_middle');
|
||||
$var['em_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','em');
|
||||
$var['logo_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','logo2');
|
||||
$var['top_spacer_middle_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','top_spacer_middle');
|
||||
$var['nav_bar_left_spacer_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','nav_bar_left_spacer');
|
||||
$var['nav_bar_left_top_bg_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','nav_bar_left_top_bg');
|
||||
|
||||
// "powered_by_color" and "_size" are is also used by number of current users thing
|
||||
$var['powered_by_size'] = '2';
|
||||
$var['powered_by_color'] = '#ffffff';
|
||||
if ($GLOBALS['phpgw_info']['server']['showpoweredbyon'] == 'top')
|
||||
{
|
||||
$var['powered_by'] = lang('Powered by phpGroupWare version x',$GLOBALS['phpgw_info']['server']['versions']['phpgwapi']);
|
||||
$tpl->set_var($var);
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['powered_by'] = '';
|
||||
$tpl->set_var($var);
|
||||
}
|
||||
|
||||
if (isset($GLOBALS['phpgw_info']['navbar']['admin']) && isset($GLOBALS['phpgw_info']['user']['preferences']['common']['show_currentusers']))
|
||||
{
|
||||
$db = $GLOBALS['phpgw']->db;
|
||||
$db->query('select count(session_id) from phpgw_sessions');
|
||||
$db->next_record();
|
||||
$var['current_users'] = '<a href="' . $GLOBALS['phpgw']->link('/index.php','menuaction=admin.uicurrentsessions.list_sessions')
|
||||
. '"> ' . lang('Current users') . ': ' . $db->f(0) . '</a>';
|
||||
$tpl->set_var($var);
|
||||
}
|
||||
else
|
||||
{
|
||||
$var['current_users'] = '';
|
||||
$tpl->set_var($var);
|
||||
}
|
||||
|
||||
$var['user_info_name'] = $GLOBALS['phpgw']->common->display_fullname();
|
||||
$now = time();
|
||||
$var['user_info_date'] =
|
||||
lang($GLOBALS['phpgw']->common->show_date($now,'l')) . ' '
|
||||
. $GLOBALS['phpgw']->common->show_date($now,$GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat']);
|
||||
$var['user_info'] = $var['user_info_name'] .' - ' .$var['user_info_date'];
|
||||
$var['user_info_size'] = '2';
|
||||
$var['user_info_color'] = '#000000';
|
||||
|
||||
// Maybe we should create a common function in the phpgw_accounts_shared.inc.php file
|
||||
// to get rid of duplicate code.
|
||||
/* if ($GLOBALS['phpgw_info']['user']['lastpasswd_change'] == 0)
|
||||
{
|
||||
$api_messages = lang('You are required to change your password during your first login')
|
||||
. '<br> Click this image on the navbar: <img src="'
|
||||
. $GLOBALS['phpgw']->common->image('preferences','navbar.gif').'">';
|
||||
}
|
||||
elseif ($GLOBALS['phpgw_info']['user']['lastpasswd_change'] < time() - (86400*30))
|
||||
{
|
||||
$api_messages = lang('it has been more then x days since you changed your password',30);
|
||||
}
|
||||
|
||||
// This is gonna change
|
||||
if (isset($cd))
|
||||
{
|
||||
$var['messages'] = $api_messages . '<br>' . checkcode($cd);
|
||||
}
|
||||
*/
|
||||
$tpl->set_var($var);
|
||||
$tpl->pfp('out','navbar');
|
||||
return;
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
$GLOBALS['phpgw']->template->fp($output,'left_part');
|
||||
}
|
||||
|
||||
function parse_nonavbar()
|
||||
{
|
||||
echo '>';
|
||||
function parse_bodypart()
|
||||
{
|
||||
$GLOBALS['phpgw_info']['flags']['body_tags']['background']=$GLOBALS['phpgw']->common->image('phpgwapi','content_spacer_middle');
|
||||
}
|
||||
|
||||
function parse_navbar_end()
|
||||
function parse_bottompart($output)
|
||||
{
|
||||
$tpl = CreateObject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);
|
||||
$tpl->set_unknowns('remove');
|
||||
|
||||
$tpl->set_file(array('footer' => 'footer.tpl'));
|
||||
$tpl->set_block('footer','B_powered_bottom','V_powered_bottom');
|
||||
$GLOBALS['phpgw']->template->set_file('parts','parts.tpl');
|
||||
$GLOBALS['phpgw']->template->set_block('parts','bottom_part');
|
||||
|
||||
if ($GLOBALS['phpgw_info']['server']['showpoweredbyon'] == 'bottom')
|
||||
{
|
||||
@ -230,14 +209,11 @@
|
||||
);
|
||||
$var['top_spacer_middle_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','top_spacer_middle');
|
||||
$var['em_bottom_img'] = $GLOBALS['phpgw']->common->image('phpgwapi','em_bottom');
|
||||
$tpl->set_var($var);
|
||||
$tpl->parse('V_powered_bottom','B_powered_bottom');
|
||||
$GLOBALS['phpgw']->template->set_var($var);
|
||||
$GLOBALS['phpgw']->template->fp($output,'bottom_part');
|
||||
}
|
||||
else
|
||||
{
|
||||
$tpl->set_var('V_powered_bottom','');
|
||||
$GLOBALS['phpgw']->template->set_var($output,'');
|
||||
}
|
||||
|
||||
$GLOBALS['phpgw']->hooks->process('navbar_end');
|
||||
$tpl->pfp('out','footer');
|
||||
}
|
37
phpgwapi/templates/idsociety/navbar.tpl → phpgwapi/templates/idsociety/parts.tpl
Executable file → Normal file
37
phpgwapi/templates/idsociety/navbar.tpl → phpgwapi/templates/idsociety/parts.tpl
Executable file → Normal file
@ -1,15 +1,5 @@
|
||||
marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" rightmargin="0" leftmargin="0" border="0"
|
||||
onLoad="MM_preloadImages('{app_images}',
|
||||
'{logout_img_hover}',
|
||||
'{preferences_img_hover}',
|
||||
'{about_img_hover}',
|
||||
'{welcome_img_hover}');"
|
||||
background="{content_spacer_middle_img}">
|
||||
<!-- the above is the continuation and finishing if the < body > element started in head.tpl
|
||||
the margin items could be merged into head, as head already supplies some
|
||||
the variables for onLoad are set in navbar -->
|
||||
|
||||
<table border="0" width="100%" height="%98" cellspacing="0" cellpadding="0">
|
||||
<!-- BEGIN top_part -->
|
||||
<table border="0" width="100%" height="%100" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<!-- top row back images are 58px high, but the row may be smaller than that -->
|
||||
<!-- row 2 images are 15 px high, so this table with these 2 rows is 58 plus 15 equals 73px high -->
|
||||
@ -55,6 +45,11 @@
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<!-- END top_part -->
|
||||
|
||||
<!-- BEGIN left_part -->
|
||||
<table border="0" width="100%" height="%100" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td width="154" align="left" valign="top" background="{nav_bar_left_spacer_img}">
|
||||
<!-- left nav table -->
|
||||
@ -66,7 +61,17 @@
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td width="100%" align="left" valign="top">
|
||||
<!-- this TD background image moved to body element -->
|
||||
<br>
|
||||
<!-- END navbar -->
|
||||
</tr>
|
||||
</table>
|
||||
<!-- END left_part -->
|
||||
|
||||
|
||||
<!-- BEGIN bottom_part -->
|
||||
<table border="0" width="100%" height="%100" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td align="center" background="{em_bottom_img}">
|
||||
<font color="{power_textcolor}">{powered}</font>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<!-- END bottom_part -->
|
Loading…
Reference in New Issue
Block a user