[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site config.inc.php,1.3,1.4 func
From: |
Michael Totschnig <address@hidden> |
Subject: |
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site config.inc.php,1.3,1.4 functions.inc.php,1.6,1.7 index.php,1.8,1.9 |
Date: |
Wed, 21 May 2003 22:36:56 -0400 |
Update of /cvsroot/phpgroupware/sitemgr/sitemgr-site
In directory subversions:/tmp/cvs-serv6703/sitemgr-site
Modified Files:
config.inc.php functions.inc.php index.php
Log Message:
make sitemgr capable of editing multiple sites
Index: config.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/sitemgr/sitemgr-site/config.inc.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** config.inc.php 4 Feb 2003 20:53:46 -0000 1.3
--- config.inc.php 22 May 2003 02:36:54 -0000 1.4
***************
*** 4,11 ****
* the site generator. *
\***********************************************************/
$sitemgr_info = array(
// add trailing slash
'phpgw_path' => '../../',
! 'htaccess_rewrite' => False
);
--- 4,12 ----
* the site generator. *
\***********************************************************/
+
$sitemgr_info = array(
// add trailing slash
'phpgw_path' => '../../',
! 'htaccess_rewrite' => False,
);
***************
*** 25,32 ****
$GLOBALS['phpgw_info']['flags']['currentapp'] = 'sitemgr-site';
! $pref = CreateObject('sitemgr.sitePreference_SO');
! $sitemgr_info = array_merge($sitemgr_info,$pref->getallprefs());
! unset($pref);
! $sitemgr_info['sitelanguages'] =
explode(',',$sitemgr_info['sitelanguages']);
//this is useful when you changed the API session class to not
overgeneralize the session cookies
--- 26,35 ----
$GLOBALS['phpgw_info']['flags']['currentapp'] = 'sitemgr-site';
! $site_url = 'http://' .
preg_replace('/\/[^\/]*$/','',$_SERVER['SERVER_NAME'] . $_SERVER['PHP_SELF']) .
'/';
!
! $GLOBALS['phpgw']->db->query("SELECT
anonymous_user,anonymous_passwd FROM phpgw_sitemgr_sites WHERE site_url =
'$site_url'");
! $GLOBALS['phpgw']->db->next_record();
! $anonymous_user = $GLOBALS['phpgw']->db->f('anonymous_user');
! $anonymous_passwd =
$GLOBALS['phpgw']->db->f('anonymous_passwd');
//this is useful when you changed the API session class to not
overgeneralize the session cookies
***************
*** 39,43 ****
if (! $GLOBALS['phpgw']->session->verify())
{
! $GLOBALS['sessionid'] =
$GLOBALS['phpgw']->session->create($sitemgr_info['anonymous-user'],$sitemgr_info['anonymous-passwd'],
'text');
if (!$GLOBALS['sessionid'])
{
--- 42,46 ----
if (! $GLOBALS['phpgw']->session->verify())
{
! $GLOBALS['sessionid'] =
$GLOBALS['phpgw']->session->create($anonymous_user,$anonymous_passwd, 'text');
if (!$GLOBALS['sessionid'])
{
Index: functions.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/sitemgr/sitemgr-site/functions.inc.php,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** functions.inc.php 4 Feb 2003 20:53:47 -0000 1.6
--- functions.inc.php 22 May 2003 02:36:54 -0000 1.7
***************
*** 57,61 ****
// like this: '//index.php?blahblahblah' -- so the code below
will remove
// the inappropriate double slashes and leave appropriate ones
! $url = $GLOBALS['sitemgr_info']['sitemgr-site-url'] . $url;
$url = substr(ereg_replace('([^:])//','\1/','s'.$url),1);
--- 57,61 ----
// like this: '//index.php?blahblahblah' -- so the code below
will remove
// the inappropriate double slashes and leave appropriate ones
! $url = $GLOBALS['sitemgr_info']['site_url'] . $url;
$url = substr(ereg_replace('([^:])//','\1/','s'.$url),1);
Index: index.php
===================================================================
RCS file: /cvsroot/phpgroupware/sitemgr/sitemgr-site/index.php,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** index.php 8 Apr 2003 18:33:36 -0000 1.8
--- index.php 22 May 2003 02:36:54 -0000 1.9
***************
*** 35,39 ****
require_once('./functions.inc.php');
! $Common_BO = CreateObject('sitemgr.Common_BO',True);
include './inc/class.ui.inc.php';
--- 35,43 ----
require_once('./functions.inc.php');
!
! $Common_BO = CreateObject('sitemgr.Common_BO');
! $Common_BO->sites->set_currentsite($site_url);
! $sitemgr_info =
array_merge($sitemgr_info,$Common_BO->sites->current_site);
! $sitemgr_info['sitelanguages'] =
explode(',',$sitemgr_info['site_languages']);
include './inc/class.ui.inc.php';
***************
*** 76,85 ****
else
{
! $objsp_so = CreateObject('sitemgr.sitePreference_SO');
! $home_page = $objsp_so->getPreference('home-page-id');
! unset($objsp_so);
! if ($home_page)
{
! $objui->displayPage($home_page);
}
else
--- 80,86 ----
else
{
! if ($sitemgr_info['home_page_id'])
{
! $objui->displayPage($sitemgr_info['home_page_id']);
}
else
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] CVS: sitemgr/sitemgr-site config.inc.php,1.3,1.4 functions.inc.php,1.6,1.7 index.php,1.8,1.9,
Michael Totschnig <address@hidden> <=
- Prev by Date:
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site/templates/3D-Fantasy main.tpl,1.3,1.4
- Next by Date:
[Phpgroupware-cvs] CVS: sitemgr/inc class.Sites_BO.inc.php,NONE,1.1 class.Sites_SO.inc.php,NONE,1.1 class.Sites_UI.inc.php,NONE,1.1 class.ACL_BO.inc.php,1.2,1.3 class.Categories_BO.inc.php,1.6,1.7 class.Categories_SO.inc.php,1.13,1.14 class.Categories_UI.inc.php,1.1,1.2 class.Common_BO.inc.php,1.2,1.3 class.Common_UI.inc.php,1.9,1.10 class.Content_BO.inc.php,1.2,1.3 class.Content_SO.inc.php,1.6,1.7 class.Content_UI.inc.php,1.4,1.5 class.MainMenu_UI.inc.php,1.6,1.7 class.Pages_BO.inc.php,1.5,1.6 class.Pages_UI.inc.php,1.1,1.2 class.Theme_BO.inc.php,1.4,1.5 class.Translations_UI.inc.php,1.3,1.4 hook_admin.inc.php,1.3,1.4 class.SiteContent_UI.inc.php,1.2,NONE class.headerFooter_BO.inc.php,1.2,NONE class.sitePreference_SO.inc.php,1.3,NONE
- Previous by thread:
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site/templates/3D-Fantasy main.tpl,1.3,1.4
- Next by thread:
[Phpgroupware-cvs] CVS: sitemgr/inc class.Sites_BO.inc.php,NONE,1.1 class.Sites_SO.inc.php,NONE,1.1 class.Sites_UI.inc.php,NONE,1.1 class.ACL_BO.inc.php,1.2,1.3 class.Categories_BO.inc.php,1.6,1.7 class.Categories_SO.inc.php,1.13,1.14 class.Categories_UI.inc.php,1.1,1.2 class.Common_BO.inc.php,1.2,1.3 class.Common_UI.inc.php,1.9,1.10 class.Content_BO.inc.php,1.2,1.3 class.Content_SO.inc.php,1.6,1.7 class.Content_UI.inc.php,1.4,1.5 class.MainMenu_UI.inc.php,1.6,1.7 class.Pages_BO.inc.php,1.5,1.6 class.Pages_UI.inc.php,1.1,1.2 class.Theme_BO.inc.php,1.4,1.5 class.Translations_UI.inc.php,1.3,1.4 hook_admin.inc.php,1.3,1.4 class.SiteContent_UI.inc.php,1.2,NONE class.headerFooter_BO.inc.php,1.2,NONE class.sitePreference_SO.inc.php,1.3,NONE
- Index(es):