diff --git a/about.php b/about.php
index 71f8ef6c42..6a5175d533 100644
--- a/about.php
+++ b/about.php
@@ -11,139 +11,137 @@
/* $Id$ */
- $GLOBALS['phpgw_info'] = array();
- $app = $_GET['app'];
- if(isset($app) && $_GET['app'] != "eGroupWare")
- {
- $GLOBALS['phpgw_info']['flags']['currentapp'] = $app;
- }
- else {
- $GLOBALS['phpgw_info']['flags']['currentapp'] = 'about';
- }
-
- $GLOBALS['phpgw_info']['flags']['disable_Template_class'] = True;
- $GLOBALS['phpgw_info']['flags']['noheader'] = True;
- include('header.inc.php');
+ $GLOBALS['egw_info'] = array();
+ $app = $_GET['app'];
+ if(isset($app) && $_GET['app'] != 'eGroupWare')
+ {
+ $GLOBALS['egw_info']['flags']['currentapp'] = $app;
+ }
+ else
+ {
+ $GLOBALS['egw_info']['flags']['currentapp'] = 'about';
+ }
- if ($app)
- {
- if (!($included = $GLOBALS['phpgw']->hooks->single('about',$app)))
- {
- $api_only = !($included = file_exists(PHPGW_INCLUDE_ROOT . "/$app/setup/setup.inc.php"));
- }
- }
- else
- {
- $api_only = True;
- }
+ $GLOBALS['egw_info']['flags']['disable_Template_class'] = True;
+ $GLOBALS['egw_info']['flags']['noheader'] = True;
+ include('header.inc.php');
- $tpl = CreateObject('phpgwapi.Template',$GLOBALS['phpgw']->common->get_tpl_dir('phpgwapi'));
- $tpl->set_file(array(
- 'phpgw_about' => 'about.tpl',
- 'phpgw_about_unknown' => 'about_unknown.tpl'
- ));
-
- $title = isset($GLOBALS['phpgw_info']['apps'][$app]) ? $GLOBALS['phpgw_info']['apps'][$app]['title'] : 'eGroupWare';
- $GLOBALS['phpgw_info']['flags']['app_header'] = lang('About %1',$title);
- $GLOBALS['phpgw']->common->phpgw_header();
-
- $tpl->set_block('phpgw_about', 'egroupware','egroupware');
- $tpl->set_block('phpgw_about', 'application','application');
-
+ if ($app)
+ {
+ if (!($included = $GLOBALS['egw']->hooks->single('about',$app)))
+ {
+ $api_only = !($included = file_exists(EGW_INCLUDE_ROOT . "/$app/setup/setup.inc.php"));
+ }
+ }
+ else
+ {
+ $api_only = True;
+ }
- if ($included)
- {
- $tpl->set_var('phpgw_app_about', about_app());
- $tpl->pparse('phpgw_about', 'application', True);
- }
- else
- {
- if ($api_only)
- {
- $tpl->set_var('phpgw_logo',$GLOBALS['phpgw']->common->image('phpgwapi','logo.gif'));
- $tpl->set_var('phpgw_version',lang('eGroupWare API version %1',$GLOBALS['phpgw_info']['server']['versions']['phpgwapi']));
- $tpl->set_var('phpgw_message',lang('%1eGroupWare%2 is a multi-user, web-based groupware suite written in %3PHP%4.',
- '','','',''));
- $tpl->pparse('out', 'egroupware');
-
- $tpl->set_var('phpgw_app_about',about_template());
+ $tpl = CreateObject('phpgwapi.Template',$GLOBALS['egw']->common->get_tpl_dir('phpgwapi'));
+ $tpl->set_file(array(
+ 'phpgw_about' => 'about.tpl',
+ 'phpgw_about_unknown' => 'about_unknown.tpl'
+ ));
+
+ $title = isset($GLOBALS['egw_info']['apps'][$app]) ? $GLOBALS['egw_info']['apps'][$app]['title'] : 'eGroupWare';
+ $GLOBALS['egw_info']['flags']['app_header'] = lang('About %1',$title);
+ $GLOBALS['egw']->common->phpgw_header();
+
+ $tpl->set_block('phpgw_about', 'egroupware','egroupware');
+ $tpl->set_block('phpgw_about', 'application','application');
+
+ if ($included)
+ {
+ $tpl->set_var('phpgw_app_about', about_app());
$tpl->pparse('phpgw_about', 'application', True);
-
- }
- else
- {
- $tpl->set_var('app_header',$app);
-
- $tpl->pparse('out','phpgw_about_unknown');
- }
- }
-
- $GLOBALS['phpgw']->common->phpgw_footer();
-
- function about_app()
- {
- global $app;
- include (PHPGW_INCLUDE_ROOT . "/$app/setup/setup.inc.php");
- $info = $setup_info[$app];
- $info['icon'] = $GLOBALS['phpgw']->common->image($app,array('navbar','nonav'));
- $info['title'] = $GLOBALS['phpgw_info']['apps'][$app]['title'];
- return about_display($info);
- }
-
-function about_template()
-{
- $template = $GLOBALS['phpgw']->common->get_tpl_dir('phpgwapi');
-
- include ($template . "/setup/setup.inc.php");
- $s = "";
- $template_info[] = $GLOBALS['egw_info']['template'][$GLOBALS['phpgw_info']['user']['preferences']['common']['template_set']];
- foreach($template_info as $info)
- {
- $s .= about_display($info);
}
- return $s;
-}
-
-
-function about_display($info)
-{
- $other_infos = array(
- 'author' => lang('Author'),
- 'maintainer' => lang('Maintainer'),
- 'version' => lang('Version'),
- 'license' => lang('License'),
- );
- if($info[icon])
+ else
{
- $icon = $info[icon];
- }
- $s = "
\n";
- if(trim($icon) != "")
- {
- $s.= "
- ![\"$info[title]\"]($icon) | $info[title] |
";
+ if ($api_only)
+ {
+ $tpl->set_var('phpgw_logo',$GLOBALS['egw']->common->image('phpgwapi','logo.gif'));
+ $tpl->set_var('phpgw_version',lang('eGroupWare API version %1',$GLOBALS['egw_info']['server']['versions']['phpgwapi']));
+ $tpl->set_var('phpgw_message',lang('%1eGroupWare%2 is a multi-user, web-based groupware suite written in %3PHP%4.',
+ '','','',''));
+ $tpl->pparse('out', 'egroupware');
+
+ $tpl->set_var('phpgw_app_about',about_template());
+ $tpl->pparse('phpgw_about', 'application', True);
}
else
{
- $s .= "
- | $info[title] |
";
- }
- if ($info['description'])
- {
- $info['description'] = lang($info['description']);
- $s .= "$info[description] |
\n";
- if ($info['note'])
- {
- $info['note'] = lang($info['note']);
- $s .= "$info[note] |
\n";
- }
+ $tpl->set_var('app_header',$app);
+ $tpl->pparse('out','phpgw_about_unknown');
+ }
}
- foreach ($other_infos as $key => $val)
+
+ $GLOBALS['egw']->common->phpgw_footer();
+
+ function about_app()
{
- if (isset($info[$key]))
+ global $app;
+ include(EGW_INCLUDE_ROOT . "/$app/setup/setup.inc.php");
+ $info = $setup_info[$app];
+ $info['icon'] = $GLOBALS['egw']->common->image($app,array('navbar','nonav'));
+ $info['title'] = $GLOBALS['egw_info']['apps'][$app]['title'];
+ return about_display($info);
+ }
+
+ function about_template()
+ {
+ $template = $GLOBALS['egw']->common->get_tpl_dir('phpgwapi');
+
+ include ($template . "/setup/setup.inc.php");
+ $s = "";
+ $template_info[] = $GLOBALS['egw_info']['template'][$GLOBALS['egw_info']['user']['preferences']['common']['template_set']];
+ foreach($template_info as $info)
{
- $s .= "$val | ";
+ $s .= about_display($info);
+ }
+ return $s;
+ }
+
+ function about_display($info)
+ {
+ $other_infos = array(
+ 'author' => lang('Author'),
+ 'maintainer' => lang('Maintainer'),
+ 'version' => lang('Version'),
+ 'license' => lang('License'),
+ );
+ if($info[icon])
+ {
+ $icon = $info[icon];
+ }
+ $s = "\n";
+ if(trim($icon) != "")
+ {
+ $s.= "
+ ![\"$info[title]\"]($icon) | $info[title] | ";
+ }
+ else
+ {
+ $s .= "
+ | $info[title] | ";
+ }
+ if ($info['description'])
+ {
+ $info['description'] = lang($info['description']);
+ $s .= "$info[description] | \n";
+ if ($info['note'])
+ {
+ $info['note'] = lang($info['note']);
+ $s .= "$info[note] | \n";
+ }
+
+ }
+ foreach ($other_infos as $key => $val)
+ {
+ if (isset($info[$key]))
+ {
+ $s .= "$val | ";
$infos = $info[$key];
for ($n = 0; is_array($info[$key][$n]) && ($infos = $info[$key][$n]) || !$n; ++$n)
{
@@ -151,10 +149,10 @@ function about_display($info)
{
$infos = array('email' => $info[$key.'_email'],'name' => $infos);
}
- elseif(!is_array($infos) && isset($info[$key.'_url']))
- {
+ elseif(!is_array($infos) && isset($info[$key.'_url']))
+ {
$infos = array('url' => $info[$key.'_url'],'name' => $infos);
- }
+ }
if (is_array($infos))
{
if ($infos['email'])
@@ -163,26 +161,26 @@ function about_display($info)
$emails = split('@| ',$infos['email']);
if (count($names) < count($emails)/2)
{
- $names = '';
+ $names = '';
}
$infos = '';
while (list($user,$domain) = $emails)
{
- if ($infos) $infos .= ' ';
- $name = $names ? array_shift($names) : $user;
- $infos .= "$name";
- array_shift($emails); array_shift($emails);
+ if ($infos) $infos .= ' ';
+ $name = $names ? array_shift($names) : $user;
+ $infos .= "$name";
+ array_shift($emails); array_shift($emails);
}
}
- elseif($infos['url'])
- {
+ elseif($infos['url'])
+ {
$img = $info[$key.'_img'];
if ($img)
{
- $img_url = $GLOBALS['phpgw']->common->image('phpgwapi',$img);
+ $img_url = $GLOBALS['egw']->common->image('phpgwapi',$img);
if (!$img_url)
{
- $img_url = $GLOBALS['phpgw']->common->image($info['name'],$img);
+ $img_url = $GLOBALS['egw']->common->image($info['name'],$img);
}
$infos = '';
}
@@ -195,16 +193,16 @@ function about_display($info)
$s .= ($n ? ' ' : '') . $infos;
}
$s .= " | \n";
+ }
}
- }
- if ($info['extra_untranslated'])
- {
- $s .= "$info[extra_untranslated] | \n";
- }
-
- $s .= " \n";
+ if ($info['extra_untranslated'])
+ {
+ $s .= " |
$info[extra_untranslated] |
\n";
+ }
- return $s;
-}
+ $s .= "
\n";
+
+ return $s;
+ }
?>
diff --git a/anon_wrapper.php b/anon_wrapper.php
index 59f7c39c00..0a7afb2ba4 100644
--- a/anon_wrapper.php
+++ b/anon_wrapper.php
@@ -21,7 +21,7 @@
$login = 'anonymous';
$passwd = 'anonymous';
- $GLOBALS['phpgw_info']['flags'] = array(
+ $GLOBALS['egw_info']['flags'] = array(
'disable_Template_class' => True,
'login' => True,
'currentapp' => 'login',
@@ -35,6 +35,6 @@
$login = 'anonymous';
$passwd = 'anonymous';
- $sessionid = $GLOBALS['phpgw']->session->create($login,$passwd,'text');
- $GLOBALS['phpgw']->redirect($GLOBALS['phpgw']->link('/index.php'));
+ $sessionid = $GLOBALS['egw']->session->create($login,$passwd,'text');
+ $GLOBALS['egw']->redirect($GLOBALS['egw']->link('/index.php'));
?>
diff --git a/header.inc.php.template b/header.inc.php.template
index caf40135f7..f504b04e3a 100644
--- a/header.inc.php.template
+++ b/header.inc.php.template
@@ -27,7 +27,7 @@
{
$GLOBALS['egw_info'] =& $GLOBALS['phpgw_info'];
}
-
+
define('EGW_SERVER_ROOT','{SERVER_ROOT}');
define('EGW_INCLUDE_ROOT','{INCLUDE_ROOT}');
define('PHPGW_SERVER_ROOT','{SERVER_ROOT}');
diff --git a/index.php b/index.php
index e552f45b55..ae4473d49d 100755
--- a/index.php
+++ b/index.php
@@ -1,7 +1,7 @@
log->message('W-BadmenuactionVariable, menuaction missing or corrupt: %1',$menuaction);
- //$phpgw->log->commit();
+ //$egw->log->message('W-BadmenuactionVariable, menuaction missing or corrupt: %1',$menuaction);
+ //$egw->log->commit();
$app = 'home';
$invalid_data = True;
}
-
if($app == 'phpgwapi')
{
$app = 'home';
$api_requested = True;
}
-
- $GLOBALS['phpgw_info']['flags'] = array(
+ $GLOBALS['egw_info']['flags'] = array(
'noheader' => True,
'nonavbar' => True,
'enable_network_class' => True,
@@ -69,45 +67,42 @@
'currentapp' => $app
);
include('./header.inc.php');
-
+
// Check if we are using windows or normal webpage
$windowed = false;
- $tpl_info = PHPGW_SERVER_ROOT . '/phpgwapi/templates/' . $GLOBALS['phpgw_info']['user']['preferences']['common']['template_set'] . '/setup/setup.inc.php';
-
+ $tpl_info = EGW_SERVER_ROOT . '/phpgwapi/templates/' . $GLOBALS['egw_info']['user']['preferences']['common']['template_set'] . '/setup/setup.inc.php';
+
if(@file_exists($tpl_info))
{
include_once($tpl_info);
-// if(isset($template_info))
+// if(isset($template_info))
// {
- if($GLOBALS['egw_info']['template'][$GLOBALS['phpgw_info']['user']['preferences']['common']['template_set']]['windowed'])
+ if($GLOBALS['egw_info']['template'][$GLOBALS['egw_info']['user']['preferences']['common']['template_set']]['windowed'])
{
$windowed = true;
- }
+ }
// }
}
-
if($app == 'home' && !$api_requested && !$windowed)
{
- if ($GLOBALS['phpgw_info']['server']['force_default_app'] && $GLOBALS['phpgw_info']['server']['force_default_app'] != 'user_choice')
+ if ($GLOBALS['egw_info']['server']['force_default_app'] && $GLOBALS['egw_info']['server']['force_default_app'] != 'user_choice')
{
- $GLOBALS['phpgw_info']['user']['preferences']['common']['default_app'] = $GLOBALS['phpgw_info']['server']['force_default_app'];
-
+ $GLOBALS['egw_info']['user']['preferences']['common']['default_app'] = $GLOBALS['egw_info']['server']['force_default_app'];
}
- if($GLOBALS['phpgw_info']['user']['preferences']['common']['default_app'] && !$hasupdates) {
-
- $GLOBALS['phpgw']->redirect_link('/'.$GLOBALS['phpgw_info']['user']['preferences']['common']['default_app'].'/index.php');
+ if($GLOBALS['egw_info']['user']['preferences']['common']['default_app'] && !$hasupdates)
+ {
+ $GLOBALS['egw']->redirect_link('/'.$GLOBALS['egw_info']['user']['preferences']['common']['default_app'].'/index.php');
}
- else {
- $GLOBALS['phpgw']->redirect_link('/home/index.php');
+ else
+ {
+ $GLOBALS['egw']->redirect_link('/home/index.php');
}
-
}
- if($windowed && $_GET['cd'] == "yes")
+ if($windowed && $_GET['cd'] == 'yes')
{
-
- $GLOBALS['phpgw_info']['flags'] = array(
+ $GLOBALS['egw_info']['flags'] = array(
'noheader' => False,
'nonavbar' => False,
'enable_network_class' => True,
@@ -115,17 +110,17 @@
'enable_nextmatchs_class' => True,
'currentapp' => 'eGroupWare'
);
- $GLOBALS['phpgw']->common->phpgw_header();
- $GLOBALS['phpgw']->common->phpgw_footer();
+ $GLOBALS['egw']->common->phpgw_header();
+ $GLOBALS['egw']->common->phpgw_footer();
}
- else {
+ else
+ {
if($api_requested)
{
-
$app = 'phpgwapi';
}
-
+
$GLOBALS[$class] = CreateObject(sprintf('%s.%s',$app,$class));
if((is_array($GLOBALS[$class]->public_functions) && $GLOBALS[$class]->public_functions[$method]) && ! $invalid_data)
{
@@ -140,9 +135,9 @@
{
if(!$app || !$class || !$method)
{
- if(@is_object($GLOBALS['phpgw']->log))
+ if(@is_object($GLOBALS['egw']->log))
{
- $GLOBALS['phpgw']->log->message(array(
+ $GLOBALS['egw']->log->message(array(
'text' => 'W-BadmenuactionVariable, menuaction missing or corrupt: %1',
'p1' => $menuaction,
'line' => __LINE__,
@@ -150,12 +145,12 @@
));
}
}
-
+
if(!is_array($GLOBALS[$class]->public_functions) || ! $$GLOBALS[$class]->public_functions[$method] && $method)
{
- if(@is_object($GLOBALS['phpgw']->log))
+ if(@is_object($GLOBALS['egw']->log))
{
- $GLOBALS['phpgw']->log->message(array(
+ $GLOBALS['egw']->log->message(array(
'text' => 'W-BadmenuactionVariable, attempted to access private method: %1',
'p1' => $method,
'line' => __LINE__,
@@ -163,17 +158,17 @@
));
}
}
- if(@is_object($GLOBALS['phpgw']->log))
+ if(@is_object($GLOBALS['egw']->log))
{
- $GLOBALS['phpgw']->log->commit();
+ $GLOBALS['egw']->log->commit();
}
-
- $GLOBALS['phpgw']->redirect_link('/home/index.php');
+
+ $GLOBALS['egw']->redirect_link('/home/index.php');
}
-
- if(!isset($GLOBALS['phpgw_info']['nofooter']))
+
+ if(!isset($GLOBALS['egw_info']['nofooter']))
{
- $GLOBALS['phpgw']->common->phpgw_footer();
+ $GLOBALS['egw']->common->phpgw_footer();
}
}
?>
diff --git a/login.php b/login.php
index d659313655..96e721a26f 100755
--- a/login.php
+++ b/login.php
@@ -89,8 +89,8 @@
if(isset($_SERVER['PHP_AUTH_USER']) && $_GET['cd'] == '1')
{
Header('HTTP/1.0 401 Unauthorized');
- Header('WWW-Authenticate: Basic realm="phpGroupWare"');
- echo 'You have to re-authentificate yourself';
+ Header('WWW-Authenticate: Basic realm="phpGroupWare"');
+ echo 'You have to re-authentificate yourself';
exit;
}
*/
@@ -134,7 +134,7 @@
return ' ';
}
}
-
+
/* Program starts here */
if($GLOBALS['egw_info']['server']['auth_type'] == 'http' && isset($_SERVER['PHP_AUTH_USER']))
@@ -152,7 +152,7 @@
if($GLOBALS['egw_info']['server']['allow_cookie_auth'])
{
$eGW_remember = unserialize(stripslashes($_COOKIE['eGW_remember']));
-
+
if($eGW_remember['login'] && $eGW_remember['passwd'] && $eGW_remember['passwd_type'])
{
$_SERVER['PHP_AUTH_USER'] = $login = $eGW_remember['login'];
@@ -161,7 +161,6 @@
$submit = True;
}
}
-
}
# Apache + mod_ssl style SSL certificate authentication
@@ -203,20 +202,20 @@
if(getenv('REQUEST_METHOD') != 'POST' && $_SERVER['REQUEST_METHOD'] != 'POST' &&
!isset($_SERVER['PHP_AUTH_USER']) && !isset($_SERVER['SSL_CLIENT_S_DN']))
{
- $GLOBALS['phpgw']->session->phpgw_setcookie('eGW_remember');
+ $GLOBALS['egw']->session->phpgw_setcookie('eGW_remember');
$GLOBALS['egw']->redirect($GLOBALS['egw']->link('/login.php','cd=5'));
}
#if(!isset($_COOKIE['eGroupWareLoginTime']))
#{
# $GLOBALS['egw']->redirect($GLOBALS['egw']->link('/login.php','cd=4'));
#}
-
+
// don't get login data again when $submit is true
if($submit == false)
{
$login = $_POST['login'];
}
-
+
//conference - for strings like vinicius@thyamad.com@default , allows
//that user have a login that is his e-mail. (viniciuscb)
$login_parts = explode('@',$login);
@@ -245,7 +244,7 @@
if(!isset($GLOBALS['sessionid']) || ! $GLOBALS['sessionid'])
{
- $GLOBALS['phpgw']->session->phpgw_setcookie('eGW_remember');
+ $GLOBALS['egw']->session->phpgw_setcookie('eGW_remember');
$GLOBALS['egw']->redirect($GLOBALS['egw_info']['server']['webserver_url'] . '/login.php?cd=' . $GLOBALS['egw']->session->cd_reason);
}
else
@@ -276,11 +275,11 @@
'login' => $login,
'passwd' => $passwd,
'passwd_type' => $passwd_type)),
- $remember_time);
- }
-
+ $remember_time);
+ }
+
if ($_POST['lang'] && preg_match('/^[a-z]{2}(-[a-z]{2}){0,1}$/',$_POST['lang']) &&
- $_POST['lang'] != $GLOBALS['egw_info']['user']['preferences']['common']['lang'])
+ $_POST['lang'] != $GLOBALS['egw_info']['user']['preferences']['common']['lang'])
{
$GLOBALS['egw']->preferences->add('common','lang',$_POST['lang'],'session');
}
@@ -293,7 +292,7 @@
if (!$forward)
{
$extra_vars['cd'] = 'yes';
- if($GLOBALS['egw']->hooks->single('hasUpdates', 'home'))
+ if($GLOBALS['egw']->hooks->single('hasUpdates', 'home'))
{
$extra_vars['hasupdates'] = 'yes';
}
@@ -388,8 +387,8 @@
if(!$GLOBALS['egw_info']['server']['show_domain_selectbox'])
{
- /* trick to make domain section disapear */
- $tmpl->set_var('domain_selection','');
+ /* trick to make domain section disapear */
+ $tmpl->set_var('domain_selection','');
}
foreach($_GET as $name => $value)
@@ -409,46 +408,46 @@
* Check is the registration app is installed, activated *
* And if the register link must be placed *
\********************************************************/
-
+
$cnf_reg =& CreateObject('phpgwapi.config','registration');
$cnf_reg->read_repository();
$config_reg = $cnf_reg->config_data;
if($config_reg[enable_registration]=='True')
{
- if ($config_reg[register_link]=='True')
- {
- $reg_link=' '.lang('Not a user yet? Register now').'
';
- }
- if ($config_reg[lostpassword_link]=='True')
- {
- $lostpw_link=' '.lang('Lost password').'
';
- }
- if ($config_reg[lostid_link]=='True')
- {
- $lostid_link=' '.lang('Lost Login Id').'
';
- }
+ if ($config_reg[register_link]=='True')
+ {
+ $reg_link=' '.lang('Not a user yet? Register now').'
';
+ }
+ if ($config_reg[lostpassword_link]=='True')
+ {
+ $lostpw_link=' '.lang('Lost password').'
';
+ }
+ if ($config_reg[lostid_link]=='True')
+ {
+ $lostid_link=' '.lang('Lost Login Id').'
';
+ }
- /* if at least one option of "registration" is activated display the registration section */
- if($config_reg[register_link]=='True' || $config_reg[lostpassword_link]=='True' || $config_reg[lostid_link]=='True')
- {
- $tmpl->set_var('register_link',$reg_link);
- $tmpl->set_var('lostpassword_link',$lostpw_link);
- $tmpl->set_var('lostid_link',$lostid_link) ;
-
- //$tmpl->set_var('registration_url',$GLOBALS['egw_info']['server']['webserver_url'] . '/registration/');
- }
- else
- {
- /* trick to make registration section disapear */
- $tmpl->set_block('login_form','registration');
- $tmpl->set_var('registration','');
- }
+ /* if at least one option of "registration" is activated display the registration section */
+ if($config_reg[register_link]=='True' || $config_reg[lostpassword_link]=='True' || $config_reg[lostid_link]=='True')
+ {
+ $tmpl->set_var('register_link',$reg_link);
+ $tmpl->set_var('lostpassword_link',$lostpw_link);
+ $tmpl->set_var('lostid_link',$lostid_link) ;
+
+ //$tmpl->set_var('registration_url',$GLOBALS['egw_info']['server']['webserver_url'] . '/registration/');
+ }
+ else
+ {
+ /* trick to make registration section disapear */
+ $tmpl->set_block('login_form','registration');
+ $tmpl->set_var('registration','');
+ }
}
// add a content-type header to overwrite an existing default charset in apache (AddDefaultCharset directiv)
header('Content-type: text/html; charset='.$GLOBALS['egw']->translation->charset());
-
+
$GLOBALS['egw_info']['server']['template_set'] = $GLOBALS['egw_info']['login_template_set'];
$tmpl->set_var('charset',$GLOBALS['egw']->translation->charset());
@@ -508,7 +507,7 @@
* Check if authentification via cookies is allowed *
* and place a time selectbox, how long cookie is valid *
\********************************************************/
-
+
if($GLOBALS['egw_info']['server']['allow_cookie_auth'])
{
$html =& CreateObject('phpgwapi.html'); /* Why the hell was nobody useing this here before??? */
@@ -525,11 +524,11 @@
}
else
{
- /* trick to make remember_me section disapear */
- $tmpl->set_block('login_form','remember_me_selection');
- $tmpl->set_var('remember_me_selection','');
+ /* trick to make remember_me section disapear */
+ $tmpl->set_block('login_form','remember_me_selection');
+ $tmpl->set_var('remember_me_selection','');
}
-
+
$tmpl->set_var('autocomplete', ($GLOBALS['egw_info']['server']['autocomplete_login'] ? 'autocomplete="off"' : ''));
$tmpl->pfp('loginout','login_form');
diff --git a/logout.php b/logout.php
index abb03ec54d..e8cfd0ecb4 100755
--- a/logout.php
+++ b/logout.php
@@ -12,8 +12,8 @@
/* $Id$ */
- $phpgw_info = array();
- $GLOBALS['phpgw_info']['flags'] = array(
+ $egw_info = array();
+ $GLOBALS['egw_info']['flags'] = array(
'disable_Template_class' => True,
'currentapp' => 'logout',
'noheader' => True,
@@ -25,44 +25,44 @@
$GLOBALS['sessionid'] = get_var('sessionid',array('GET','COOKIE'));
$GLOBALS['kp3'] = get_var('kp3',array('GET','COOKIE'));
- $verified = $GLOBALS['phpgw']->session->verify();
+ $verified = $GLOBALS['egw']->session->verify();
if ($verified)
{
- if (file_exists($GLOBALS['phpgw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid']))
+ if (file_exists($GLOBALS['egw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid']))
{
- $dh = opendir($GLOBALS['phpgw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid']);
+ $dh = opendir($GLOBALS['egw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid']);
while ($file = readdir($dh))
{
if ($file != '.' && $file != '..')
{
- unlink($GLOBALS['phpgw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid'] . SEP . $file);
+ unlink($GLOBALS['egw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid'] . SEP . $file);
}
}
closedir($dh);
- rmdir($GLOBALS['phpgw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid']);
+ rmdir($GLOBALS['egw_info']['server']['temp_dir'] . SEP . $GLOBALS['sessionid']);
}
- $GLOBALS['phpgw']->hooks->process('logout');
- $GLOBALS['phpgw']->session->destroy($GLOBALS['sessionid'],$GLOBALS['kp3']);
+ $GLOBALS['egw']->hooks->process('logout');
+ $GLOBALS['egw']->session->destroy($GLOBALS['sessionid'],$GLOBALS['kp3']);
}
else
{
- if(is_object($GLOBALS['phpgw']->log))
+ if(is_object($GLOBALS['egw']->log))
{
- $GLOBALS['phpgw']->log->write(array(
+ $GLOBALS['egw']->log->write(array(
'text' => 'W-VerifySession, could not verify session during logout',
'line' => __LINE__,
'file' => __FILE__
));
}
}
- $GLOBALS['phpgw']->session->phpgw_setcookie('eGW_remember');
- $GLOBALS['phpgw']->session->phpgw_setcookie('sessionid');
- $GLOBALS['phpgw']->session->phpgw_setcookie('kp3');
- $GLOBALS['phpgw']->session->phpgw_setcookie('domain');
- if($GLOBALS['phpgw_info']['server']['sessions_type'] == 'php4')
+ $GLOBALS['egw']->session->phpgw_setcookie('eGW_remember');
+ $GLOBALS['egw']->session->phpgw_setcookie('sessionid');
+ $GLOBALS['egw']->session->phpgw_setcookie('kp3');
+ $GLOBALS['egw']->session->phpgw_setcookie('domain');
+ if($GLOBALS['egw_info']['server']['sessions_type'] == 'php4')
{
- $GLOBALS['phpgw']->session->phpgw_setcookie(PHPGW_PHPSESSID);
+ $GLOBALS['egw']->session->phpgw_setcookie(EGW_PHPSESSID);
}
- $GLOBALS['phpgw']->redirect($GLOBALS['phpgw_info']['server']['webserver_url'].'/login.php?cd=1');
+ $GLOBALS['egw']->redirect($GLOBALS['egw_info']['server']['webserver_url'].'/login.php?cd=1');
?>
diff --git a/notify.php b/notify.php
index 40af5dad7d..e9dbfd8133 100644
--- a/notify.php
+++ b/notify.php
@@ -11,15 +11,15 @@
/* $Id$ */
- $phpgw_info = array();
- $GLOBALS['phpgw_info']['flags'] = array(
+ $egw_info = array();
+ $GLOBALS['egw_info']['flags'] = array(
'noheader' => True,
'nonavbar' => True,
'disable_Template_class' => True,
'currentapp' => 'notifywindow'
);
include('header.inc.php');
- $charSet = $GLOBALS['phpgw']->translation->charset();
+ $charSet = $GLOBALS['egw']->translation->charset();
?>
@@ -29,11 +29,11 @@
?>
Notify Window
-
+
- |
+ |
hooks->process('notifywindow');
+ $GLOBALS['egw']->hooks->process('notifywindow');
?>
diff --git a/notify_simple.php b/notify_simple.php
index 9e35e30ff6..f89d4fcc0e 100644
--- a/notify_simple.php
+++ b/notify_simple.php
@@ -11,8 +11,8 @@
/* $Id$ */
- $phpgw_info = array();
- $GLOBALS['phpgw_info']['flags'] = array(
+ $egw_info = array();
+ $GLOBALS['egw_info']['flags'] = array(
'noheader' => True,
'nonavbar' => True,
'disable_Template_class' => True,
@@ -21,6 +21,6 @@
include('./header.inc.php');
echo '';
- $GLOBALS['phpgw']->hooks->process('notifywindow_simple',array('email'));
+ $GLOBALS['egw']->hooks->process('notifywindow_simple',array('email'));
echo '';
?>
diff --git a/notifyxml.php b/notifyxml.php
index ecf900f918..c9c568cb75 100755
--- a/notifyxml.php
+++ b/notifyxml.php
@@ -12,38 +12,35 @@
/* $Id$ */
- $phpgw_info = array();
- $GLOBALS['phpgw_info']['flags'] = array(
- 'noheader' => True,
- 'nonavbar' => True,
- 'disable_Template_class' => True,
- 'currentapp' => 'notifywindow'
- );
- include('header.inc.php');
- header("Content-type: text/xml");
+ $egw_info = array();
+ $GLOBALS['egw_info']['flags'] = array(
+ 'noheader' => True,
+ 'nonavbar' => True,
+ 'disable_Template_class' => True,
+ 'currentapp' => 'notifywindow'
+ );
+ include('header.inc.php');
+ header("Content-type: text/xml");
- header( "Expires: Mon, 26 Jul 1997 05:00:00 GMT" );
- header( "Last-Modified: " . gmdate( "D, d M Y H:i:s" ) . "GMT" );
- header( "Cache-Control: no-cache, must-revalidate" );
- header( "Pragma: no-cache" );
+ header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
+ header("Last-Modified: " . gmdate( "D, d M Y H:i:s") . "GMT");
+ header("Cache-Control: no-cache, must-revalidate");
+ header("Pragma: no-cache");
- echo '';
- $apps = $GLOBALS['phpgw']->hooks->process('notify');
- echo "\r\n\r\n";
- foreach($apps as $app => $message) {
-
- if($message != "")
- {
- $title = $GLOBALS['phpgw_info']['apps'][$app]['title'];
-
- echo " ".$title."
- ".$GLOBALS['phpgw']->link("/".$app."/index.php")."
- ".$message." \r\n";
-
- }
- }
- echo "";
+ echo '';
+ $apps = $GLOBALS['egw']->hooks->process('notify');
+ echo "\r\n\r\n";
+ foreach($apps as $app => $message)
+ {
+ if($message != '')
+ {
+ $title = $GLOBALS['egw_info']['apps'][$app]['title'];
+ echo " ".$title."
+".$GLOBALS['egw']->link("/".$app."/index.php")."
+".$message." \r\n";
+ }
+ }
+ echo "";
?>
-
diff --git a/set_box.php b/set_box.php
index 1772cf556c..41dffc992d 100755
--- a/set_box.php
+++ b/set_box.php
@@ -12,69 +12,69 @@
/* $Id$ */
- $GLOBALS['phpgw_info']['flags'] = Array(
- 'noheader' => True,
- 'nofooter' => True,
- 'currentapp' => 'home'
+ $GLOBALS['egw_info']['flags'] = Array(
+ 'noheader' => True,
+ 'nofooter' => True,
+ 'currentapp' => 'home'
);
include('header.inc.php');
// if(basename($HTTP_REFERER) != 'home.php')
// {
-// Header('Location: '.$GLOBALS['phpgw']->link('/home.php'));
-// $GLOBALS['phpgw']->common->phpgw_exit();
+// Header('Location: '.$GLOBALS['egw']->link('/home.php'));
+// $GLOBALS['egw']->common->phpgw_exit();
// }
- @reset($GLOBALS['phpgw_info']['user']['preferences']);
- //_debug_array($GLOBALS['phpgw_info']['user']['preferences']['portal_order']);
-// $GLOBALS['phpgw']->preferences->delete('portal_order');
-// unset($GLOBALS['phpgw_info']['user']['preferences']['portal_order']);
-// $GLOBALS['phpgw']->preferences->save_repository();
+ @reset($GLOBALS['egw_info']['user']['preferences']);
+ //_debug_array($GLOBALS['egw_info']['user']['preferences']['portal_order']);
+// $GLOBALS['egw']->preferences->delete('portal_order');
+// unset($GLOBALS['egw_info']['user']['preferences']['portal_order']);
+// $GLOBALS['egw']->preferences->save_repository();
function move_boxes($curr_position,$new_order,$offset,$value_to_check,$max_num)
{
//echo "MOVE: $curr_position,$new_order,$offset,$value_to_check,$max_num
";
- if(isset($GLOBALS['phpgw_info']['user']['preferences']['portal_order'][$new_order]))
+ if(isset($GLOBALS['egw_info']['user']['preferences']['portal_order'][$new_order]))
{
if($new_order == $max_num)
{
if($offset < 0)
{
- @ksort($GLOBALS['phpgw_info']['user']['preferences']['portal_order']);
+ @ksort($GLOBALS['egw_info']['user']['preferences']['portal_order']);
}
else
{
- @krsort($GLOBALS['phpgw_info']['user']['preferences']['portal_order']);
+ @krsort($GLOBALS['egw_info']['user']['preferences']['portal_order']);
}
- while(list($seq_order,$appid) = each($GLOBALS['phpgw_info']['user']['preferences']['portal_order']))
+ while(list($seq_order,$appid) = each($GLOBALS['egw_info']['user']['preferences']['portal_order']))
{
if($seq_order != $value_to_check)
{
$prev_seq = $seq_order + $offset;
- $GLOBALS['phpgw']->preferences->delete('portal_order',$prev_seq);
- $GLOBALS['phpgw']->preferences->add('portal_order',$prev_seq,$appid);
+ $GLOBALS['egw']->preferences->delete('portal_order',$prev_seq);
+ $GLOBALS['egw']->preferences->add('portal_order',$prev_seq,$appid);
}
}
}
else
{
- $GLOBALS['phpgw']->preferences->delete('portal_order',$curr_position);
- $GLOBALS['phpgw']->preferences->add('portal_order',$curr_position,(int)$GLOBALS['phpgw_info']['user']['preferences']['portal_order'][$new_order]);
+ $GLOBALS['egw']->preferences->delete('portal_order',$curr_position);
+ $GLOBALS['egw']->preferences->add('portal_order',$curr_position,(int)$GLOBALS['egw_info']['user']['preferences']['portal_order'][$new_order]);
}
}
- $GLOBALS['phpgw']->preferences->delete('portal_order',$new_order);
- $GLOBALS['phpgw']->preferences->add('portal_order',$new_order,(int)$_GET['app']);
-
- $GLOBALS['phpgw']->preferences->save_repository();
+ $GLOBALS['egw']->preferences->delete('portal_order',$new_order);
+ $GLOBALS['egw']->preferences->add('portal_order',$new_order,(int)$_GET['app']);
+
+ $GLOBALS['egw']->preferences->save_repository();
}
//error_reporting(E_ALL);
switch($_GET['control'])
{
- //print_debug('set_box', $GLOBALS['phpgw_info']['user']['preferences']['portal_order']),'app',5);
+ //print_debug('set_box', $GLOBALS['egw_info']['user']['preferences']['portal_order']),'app',5);
case 'up':
- $curr_position = $GLOBALS['phpgw']->common->find_portal_order((int)$_GET['app']);
- $max_count = count($GLOBALS['phpgw_info']['user']['preferences']['portal_order']) - 1;
+ $curr_position = $GLOBALS['egw']->common->find_portal_order((int)$_GET['app']);
+ $max_count = count($GLOBALS['egw_info']['user']['preferences']['portal_order']) - 1;
$offset = -1;
if($curr_position <= 0)
{
@@ -87,8 +87,8 @@
move_boxes($curr_position,$new_order,$offset,0,$max_count);
break;
case 'down':
- $curr_position = $GLOBALS['phpgw']->common->find_portal_order((int)$_GET['app']);
- $max_count = count($GLOBALS['phpgw_info']['user']['preferences']['portal_order']) - 1;
+ $curr_position = $GLOBALS['egw']->common->find_portal_order((int)$_GET['app']);
+ $max_count = count($GLOBALS['egw_info']['user']['preferences']['portal_order']) - 1;
$offset = 1;
if($curr_position >= $max_count)
{
@@ -106,7 +106,6 @@
default:
}
- header('Location: '.$GLOBALS['phpgw']->link('/home.php'));
- $GLOBALS['phpgw']->common->phpgw_exit();
+ header('Location: '.$GLOBALS['egw']->link('/home.php'));
+ $GLOBALS['egw']->common->phpgw_exit();
?>
-
diff --git a/soap.php b/soap.php
index b60b646ff2..34f303fc93 100644
--- a/soap.php
+++ b/soap.php
@@ -12,8 +12,8 @@
/* $Id$ */
- $phpgw_info = array();
- $GLOBALS['phpgw_info']['flags'] = array(
+ $egw_info = array();
+ $GLOBALS['egw_info']['flags'] = array(
'disable_Template_class' => True,
'currentapp' => 'login',
'noheader' => True,
@@ -23,7 +23,7 @@
$GLOBALS['server'] = CreateObject('phpgwapi.soap_server');
/* _debug_array($GLOBALS['server']);exit; */
- /* include(PHPGW_API_INC . '/soaplib.soapinterop.php'); */
+ /* include(EGW_API_INC . '/soaplib.soapinterop.php'); */
/* Note: this command only available under Apache */
$headers = getallheaders();
@@ -36,11 +36,11 @@
$auth = base64_decode(trim($tmp));
list($sessionid,$kp3) = split(':',$auth);
- if($GLOBALS['phpgw']->session->verify($sessionid,$kp3))
+ if($GLOBALS['egw']->session->verify($sessionid,$kp3))
{
$GLOBALS['server']->authed = True;
}
- elseif($GLOBALS['phpgw']->session->verify_server($sessionid,$kp3))
+ elseif($GLOBALS['egw']->session->verify_server($sessionid,$kp3))
{
$GLOBALS['server']->authed = True;
}
diff --git a/xmlrpc.php b/xmlrpc.php
index cba595e046..527abbc895 100644
--- a/xmlrpc.php
+++ b/xmlrpc.php
@@ -15,8 +15,8 @@
/*list($usec, $sec) = explode(" ", microtime());
$GLOBALS['concisus']['script_start'] = ((float)$usec + (float)$sec);*/
- $GLOBALS['phpgw_info'] = array();
- $GLOBALS['phpgw_info']['flags'] = array(
+ $GLOBALS['egw_info'] = array();
+ $GLOBALS['egw_info']['flags'] = array(
'currentapp' => 'login',
'noheader' => True,
'disable_Template_class' => True
@@ -24,12 +24,12 @@
include('header.inc.php');
//viniciuscb: a secure way to know if we're in a xmlrpc call...
- $GLOBALS['phpgw_info']['server']['xmlrpc'] = true;
+ $GLOBALS['egw_info']['server']['xmlrpc'] = true;
$server = CreateObject('phpgwapi.xmlrpc_server');
-
+
/* uncomment here if you want to show all of the testing functions for compatibility */
- //include(PHPGW_API_INC . '/xmlrpc.interop.php');
+ //include(EGW_API_INC . '/xmlrpc.interop.php');
/* Note: this command only available under Apache */
$headers = getallheaders();
@@ -49,11 +49,11 @@
$sessionid = get_var('sessionid',array('COOKIE','GET'));
$kp3 = get_var('kp3',array('COOKIE','GET'));
}
- $server->authed = $GLOBALS['phpgw']->session->verify($sessionid,$kp3);
+ $server->authed = $GLOBALS['egw']->session->verify($sessionid,$kp3);
if (!$server->authed and isset($_SERVER['PHP_AUTH_USER']) and isset($_SERVER['PHP_AUTH_PW']))
{
- $authed = $GLOBALS['phpgw']->session->create($login.'@'.$domain, $_SERVER['PHP_AUTH_PW'], 'text');
+ $authed = $GLOBALS['egw']->session->create($login.'@'.$domain, $_SERVER['PHP_AUTH_PW'], 'text');
if ($authed)
{