2003-08-28 16:31:11 +02:00
|
|
|
<?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$ */
|
|
|
|
|
2003-11-19 21:44:54 +01:00
|
|
|
if($GLOBALS['phpgw_info']['user']['preferences']['common']['show_generation_time'])
|
|
|
|
{
|
|
|
|
$mtime = microtime();
|
2003-12-19 10:13:29 +01:00
|
|
|
$mtime = explode(' ',$mtime);
|
2003-11-19 21:44:54 +01:00
|
|
|
$mtime = $mtime[1] + $mtime[0];
|
|
|
|
$GLOBALS['page_start_time'] = $mtime;
|
|
|
|
}
|
2003-12-19 10:13:29 +01:00
|
|
|
|
2003-12-15 01:05:28 +01:00
|
|
|
// get used language code
|
2003-12-19 10:13:29 +01:00
|
|
|
$lang_code = 'en';
|
2003-12-15 01:05:28 +01:00
|
|
|
|
2003-08-28 16:31:11 +02:00
|
|
|
$bodyheader = ' bgcolor="' . $GLOBALS['phpgw_info']['theme']['bg_color'] . '" alink="'
|
2003-10-30 15:43:16 +01:00
|
|
|
. $GLOBALS['phpgw_info']['theme']['alink'] . '" link="' . $GLOBALS['phpgw_info']['theme']['link'] . '" vlink="'
|
|
|
|
. $GLOBALS['phpgw_info']['theme']['vlink'] . '"';
|
2003-08-28 16:31:11 +02:00
|
|
|
|
2003-10-30 15:43:16 +01:00
|
|
|
if(!$GLOBALS['phpgw_info']['server']['htmlcompliant'])
|
2003-08-28 16:31:11 +02:00
|
|
|
{
|
|
|
|
$bodyheader .= '';
|
|
|
|
}
|
|
|
|
|
2003-10-23 20:30:35 +02:00
|
|
|
#_debug_array($GLOBALS['phpgw_info']['user']['preferences']['common']);
|
2003-08-28 16:31:11 +02:00
|
|
|
$theme_css = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/idots/css/'.$GLOBALS['phpgw_info']['user']['preferences']['common']['theme'].'.css';
|
2003-10-30 15:43:16 +01:00
|
|
|
if(!file_exists($theme_css))
|
2003-08-28 16:31:11 +02:00
|
|
|
{
|
2003-10-23 20:30:35 +02:00
|
|
|
$theme_css = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/idots/css/'.$GLOBALS['phpgw_info']['user']['preferences']['common']['theme'].'.css';
|
2003-08-28 16:31:11 +02:00
|
|
|
}
|
2003-10-23 17:20:19 +02:00
|
|
|
|
2003-12-15 01:05:28 +01:00
|
|
|
//pngfix defaults to yes
|
|
|
|
if(!$GLOBALS['phpgw_info']['user']['preferences']['common']['disable_pngfix'])
|
|
|
|
{
|
|
|
|
$pngfix_src = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/idots/js/pngfix.js';
|
|
|
|
$pngfix ='<!-- This solves the Internet Explorer PNG-transparency bug, but only for IE 5.5 and higher -->
|
|
|
|
<!--[if gte IE 5.5000]>
|
2004-01-09 19:44:55 +01:00
|
|
|
<script src="'.$pngfix_src.'" type="text/javascript">
|
2003-12-15 01:05:28 +01:00
|
|
|
</script>
|
|
|
|
<![endif]-->';
|
|
|
|
}
|
2003-10-30 15:43:16 +01:00
|
|
|
|
2003-12-19 10:13:29 +01:00
|
|
|
if(!$GLOBALS['phpgw_info']['user']['preferences']['common']['disable_slider_effects'])
|
|
|
|
{
|
|
|
|
$slider_effects_src = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/idots/js/slidereffects.js';
|
2004-01-09 19:45:58 +01:00
|
|
|
$slider_effects = '<script src="'.$slider_effects_src.'" type="text/javascript">
|
2003-12-19 10:13:29 +01:00
|
|
|
</script>';
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
$simple_show_hide_src = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/templates/idots/js/simple_show_hide.js';
|
2004-01-09 19:45:58 +01:00
|
|
|
$simple_show_hide = '<script src="'.$simple_show_hide_src.'" type="text/javascript">
|
2003-12-19 10:13:29 +01:00
|
|
|
</script>';
|
|
|
|
}
|
|
|
|
|
2004-02-10 00:44:46 +01:00
|
|
|
// 030204 ndee for calling foldertree
|
|
|
|
|
|
|
|
$foldertree_src = $GLOBALS['phpgw_info']['server']['webserver_url'] . '/phpgwapi/js/foldertree/foldertree.js';
|
|
|
|
$js_foldertree = '<script src="'.$foldertree_src.'" type="text/javascript"></script>';
|
|
|
|
|
2003-08-28 16:31:11 +02:00
|
|
|
$tpl = CreateObject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);
|
|
|
|
$tpl->set_unknowns('remove');
|
2004-01-01 23:57:07 +01:00
|
|
|
$tpl->set_file(array('_head' => 'head.tpl'));
|
|
|
|
$tpl->set_block('_head','head');
|
2003-08-28 16:31:11 +02:00
|
|
|
|
|
|
|
$app = $GLOBALS['phpgw_info']['flags']['currentapp'];
|
|
|
|
$app = $app ? ' ['.(isset($GLOBALS['phpgw_info']['apps'][$app]) ? $GLOBALS['phpgw_info']['apps'][$app]['title'] : lang($app)).']':'';
|
|
|
|
|
2003-10-30 15:43:16 +01:00
|
|
|
$var = Array(
|
2003-08-28 16:31:11 +02:00
|
|
|
'img_icon' => PHPGW_IMAGES_DIR . '/favicon.ico',
|
|
|
|
'img_shortcut' => PHPGW_IMAGES_DIR . '/favicon.ico',
|
2003-10-30 15:43:16 +01:00
|
|
|
'pngfix' => $pngfix,
|
2003-12-15 01:05:28 +01:00
|
|
|
'slider_effects'=> $slider_effects,
|
|
|
|
'simple_show_hide'=> $simple_show_hide,
|
|
|
|
'lang_code'=> $lang_code,
|
2003-10-05 04:06:11 +02:00
|
|
|
'charset' => $GLOBALS['phpgw']->translation->charset(),
|
2003-10-30 15:43:16 +01:00
|
|
|
'font_family' => $GLOBALS['phpgw_info']['theme']['font'],
|
|
|
|
'website_title' => $GLOBALS['phpgw_info']['server']['site_title'].$app,
|
|
|
|
'body_tags' => $bodyheader .' '. $GLOBALS['phpgw']->common->get_body_attribs(),
|
|
|
|
'theme_css' => $theme_css,
|
|
|
|
'css' => $GLOBALS['phpgw']->common->get_css(),
|
|
|
|
'java_script' => $GLOBALS['phpgw']->common->get_java_script(),
|
2004-02-10 18:12:01 +01:00
|
|
|
'js_foldertree' => $js_foldertree
|
2003-08-28 16:31:11 +02:00
|
|
|
);
|
|
|
|
$tpl->set_var($var);
|
|
|
|
$tpl->pfp('out','head');
|
|
|
|
unset($tpl);
|
|
|
|
?>
|