link($referer,array('msg' => $content['msg'])))."';";
- }
+ $content['js'] = "opener.location.search += (opener.location.search ? '&msg=' : '?msg=')+'{$content['msg']}';";
}
$content[$tabs] = $active_tab;
if ((int) $content['pm_id'] != (int) $content['old_pm_id'])
@@ -995,22 +992,22 @@ class infolog_ui
);
if (!($content['msg'] = $this->delete($info_id,$referer,'edit'))) return; // checks ACL first
- $content['js'] = "opener.location.href='".$GLOBALS['egw']->link($referer,array('msg' => $content['msg']))."';";
+ $content['js'] = "opener.location.href='".egw::link($referer,array('msg' => $content['msg']))."';";
}
// called again after delete confirmation dialog
elseif ($button == 'deleted' && $content['msg'])
{
- $content['js'] = "opener.location.href='".$GLOBALS['egw']->link($referer,array('msg' => $content['msg']))."';";
+ $content['js'] = "opener.location.href='".egw::link($referer,array('msg' => $content['msg']))."';";
}
if ($button == 'save' || $button == 'cancel' || $button == 'delete' || $button == 'deleted')
{
if ($no_popup)
{
- $GLOBALS['egw']->redirect_link($referer,array('msg' => $content['msg']));
+ egw::redirect_link($referer,array('msg' => $content['msg']));
}
$content['js'] .= 'window.close();';
echo '';
- $GLOBALS['egw']->common->egw_exit();
+ common::egw_exit();
}
if ($content['js']) $content['js'] = '';
}
@@ -1029,7 +1026,7 @@ class infolog_ui
$info_id = $content ? $content : get_var('info_id', array('POST','GET'));
$type = $type ? $type : get_var('type', array('POST','GET'));
$ref=$referer = $referer !== '' ? $referer : ($_GET['referer'] ? $_GET['referer'] :
- $GLOBALS['egw']->common->get_referer('/index.php?menuaction=infolog.infolog_ui.index'));
+ common::get_referer('/index.php?menuaction=infolog.infolog_ui.index'));
$referer = preg_replace('/([&?]{1})msg=[^&]+&?/','\\1',$referer); // remove previou/old msg from referer
$no_popup = $_GET['no_popup'];
$print = (int) $_REQUEST['print'];
@@ -1100,14 +1097,14 @@ class infolog_ui
{
if ($no_popup)
{
- $GLOBALS['egw']->common->egw_header();
+ common::egw_header();
parse_navbar();
echo ''.lang('Permission denied')."
\n";
- $GLOBALS['egw']->common->egw_exit();
+ common::egw_exit();
}
$js = "alert('".lang('Permission denied')."'); window.close();";
echo '';
- $GLOBALS['egw']->common->egw_exit();
+ common::egw_exit();
}
}
$content['links'] = $content['link_to'] = array(
@@ -1333,7 +1330,7 @@ class infolog_ui
{
$icon = $this->icons[$cat][$id];
}
- if ($icon && !is_readable($GLOBALS['egw']->common->get_image_dir() . '/' . $icon))
+ if ($icon && !is_readable(common::get_image_dir() . '/' . $icon))
{
$icon = False;
}
@@ -1407,11 +1404,11 @@ class infolog_ui
}
if($_POST['cancel'] || $_POST['save'])
{
- $GLOBALS['egw']->redirect_link('/infolog/index.php');
+ egw::redirect_link('/infolog/index.php');
}
$GLOBALS['egw_info']['flags']['app_header'] = lang('InfoLog').' - '.lang('Site configuration');
- $GLOBALS['egw']->common->egw_header();
+ common::egw_header();
$GLOBALS['egw']->template->set_file(array('info_admin_t' => 'admin.tpl'));
$GLOBALS['egw']->template->set_block('info_admin_t', 'admin_line');
@@ -1536,9 +1533,9 @@ class infolog_ui
strtotime($mailcontent['headers']['DATE'])
));
}
- $GLOBALS['egw']->common->egw_header();
+ common::egw_header();
echo "";
- $GLOBALS['egw']->common->egw_exit();
+ common::egw_exit();
exit;
}