[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] sitemgr/sitemgr-link index.php [skwashd-16-compat]
From: |
Dave Hall |
Subject: |
[Phpgroupware-cvs] sitemgr/sitemgr-link index.php [skwashd-16-compat] |
Date: |
Sun, 07 Jan 2007 03:16:06 +0000 |
CVSROOT: /cvsroot/phpgroupware
Module name: sitemgr
Branch: skwashd-16-compat
Changes by: Dave Hall <skwashd> 07/01/07 03:16:06
Modified files:
sitemgr-link : index.php
Log message:
make redirects work
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/sitemgr/sitemgr-link/index.php?cvsroot=phpgroupware&only_with_tag=skwashd-16-compat&r1=1.7.2.4&r2=1.7.2.4.4.1
Patches:
Index: index.php
===================================================================
RCS file: /cvsroot/phpgroupware/sitemgr/sitemgr-link/index.php,v
retrieving revision 1.7.2.4
retrieving revision 1.7.2.4.4.1
diff -u -b -r1.7.2.4 -r1.7.2.4.4.1
--- index.php 7 Apr 2004 05:42:25 -0000 1.7.2.4
+++ index.php 7 Jan 2007 03:16:06 -0000 1.7.2.4.4.1
@@ -17,12 +17,11 @@
);
if (file_exists('../header.inc.php'))
{
- include('../header.inc.php');
+ include_once('../header.inc.php');
}
else
{
- echo "You need to make sure the sitemgr-link app is in the
phpgroupware directory. If you made a symbolic link... it isn't working.";
- die();
+ die(lang('you need to make sure the sitemgr-link app is in the
phpgroupware directory. if you made a symbolic link... it isn\'t working.'));
}
$site_id = get_var('site_id', array('POST', 'GET'), 0);
@@ -31,28 +30,21 @@
if((isset($GLOBALS['phpgw_info']['user']['preferences']['sitemgr-link']['default_site'])
&&
$GLOBALS['phpgw_info']['user']['preferences']['sitemgr-link']['default_site']
!= 0)
|| $site_id
- || ($sites_bo->getnumberofsites() == 1)
- )
+ || $sites_bo->getnumberofsites() == 1 )
{
- if( $site_id) //if one site then there is only one choice
- {
-
$GLOBALS['phpgw_info']['user']['preferences']['sitemgr']['currentsite'] =
$site_id;
- }
-
- $siteinfo = $sites_bo->get_currentsiteinfo();
+ $siteinfo = $sites_bo->get_currentsiteinfo($site_id);
$location = $siteinfo['site_url'];
$dir = $siteinfo['site_dir'];
$sitemgr_info['site_url'] = $location;
if ($location && file_exists($dir . '/functions.inc.php'))
{
require_once($dir . '/functions.inc.php');
- Header('Location: ' . sitemgr_link(array('PHPSESSID' =>
session_id())));
+ Header('Location: ' . sitemgr_link(array(), true) );
exit;
}
else
{
- $GLOBALS['phpgw']->common->phpgw_header();
- echo parse_navbar();
+ $GLOBALS['phpgw']->common->phpgw_header(true);
$aclbo = CreateObject('sitemgr.ACL_BO', True);
echo '<table width="50%"><tr><td>';
if ($aclbo->is_admin())
@@ -70,7 +62,7 @@
echo lang('Your administrator has not yet setup
the web content manager for public viewing. Please contact your administrator
to get this fixed.');
}
echo '</td></tr></table>';
- $GLOBALS['phpgw']->common->phpgw_footer();
+ $GLOBALS['phpgw']->common->phpgw_footer(true);
}
}
else
@@ -81,8 +73,7 @@
{
$sites[$key] = $data['site_name'];
}
- $GLOBALS['phpgw']->common->phpgw_header();
- echo parse_navbar();
+ $GLOBALS['phpgw']->common->phpgw_header(true);
// i know this bad, but it is a quick thing - for now.
?>
<h2><?php echo lang('select site to view') ?></h2>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] sitemgr/sitemgr-link index.php [skwashd-16-compat],
Dave Hall <=