[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.3.2.1
From: |
Michael Totschnig <address@hidden> |
Subject: |
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site config.inc.php,1.3,1.3.2.1 functions.inc.php,1.6,1.6.2.1 index.php,1.7.2.1,1.7.2.2 |
Date: |
Mon, 23 Jun 2003 16:31:23 -0400 |
Update of /cvsroot/phpgroupware/sitemgr/sitemgr-site
In directory subversions:/tmp/cvs-serv14915/sitemgr-site
Modified Files:
Tag: Version-0_9_16-branch
config.inc.php functions.inc.php index.php
Log Message:
sync up with HEAD
Index: config.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/sitemgr/sitemgr-site/config.inc.php,v
retrieving revision 1.3
retrieving revision 1.3.2.1
diff -C2 -r1.3 -r1.3.2.1
*** config.inc.php 4 Feb 2003 20:53:46 -0000 1.3
--- config.inc.php 23 Jun 2003 20:31:21 -0000 1.3.2.1
***************
*** 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,33 ****
$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
if ($GLOBALS['HTTP_GET_VARS']['PHPSESSID'])
--- 26,41 ----
$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'");
+ if ($GLOBALS['phpgw']->db->next_record())
+ {
+ $anonymous_user =
$GLOBALS['phpgw']->db->f('anonymous_user');
+ $anonymous_passwd =
$GLOBALS['phpgw']->db->f('anonymous_passwd');
+ }
+ else
+ {
+ die(lang('THERE IS NO WEBSITE CONFIGURED FOR URL %1.
NOTIFY THE ADMINISTRATOR.',$site_url));
+ }
//this is useful when you changed the API session class to not
overgeneralize the session cookies
if ($GLOBALS['HTTP_GET_VARS']['PHPSESSID'])
***************
*** 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'])
{
--- 47,51 ----
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.6.2.1
diff -C2 -r1.6 -r1.6.2.1
*** functions.inc.php 4 Feb 2003 20:53:47 -0000 1.6
--- functions.inc.php 23 Jun 2003 20:31:21 -0000 1.6.2.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']['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.7.2.1
retrieving revision 1.7.2.2
diff -C2 -r1.7.2.1 -r1.7.2.2
*** index.php 8 Apr 2003 18:13:04 -0000 1.7.2.1
--- index.php 23 Jun 2003 20:31:21 -0000 1.7.2.2
***************
*** 22,30 ****
'nonavbar' => True
);
- require_once('./security.inc.php');
if (file_exists('./config.inc.php'))
{
! require_once('./config.inc.php');
}
else
--- 22,29 ----
'nonavbar' => True
);
if (file_exists('./config.inc.php'))
{
! include('./config.inc.php');
}
else
***************
*** 33,48 ****
}
! require_once('./functions.inc.php');
!
! $Common_BO = CreateObject('sitemgr.Common_BO',True);
include './inc/class.ui.inc.php';
include './inc/class.sitebo.inc.php';
include './inc/class.Template3.inc.php';
!
! $objui = new ui;
! //I move the creation of the bo here, so that in the template we have
access to it without creating it a second time
$objbo = new sitebo;
$objbo->setsitemgrPreferredLanguage();
$page = CreateObject('sitemgr.Page_SO');
--- 32,48 ----
}
! include('./functions.inc.php');
include './inc/class.ui.inc.php';
include './inc/class.sitebo.inc.php';
include './inc/class.Template3.inc.php';
!
! $Common_BO = CreateObject('sitemgr.Common_BO');
$objbo = new sitebo;
+ $Common_BO->sites->set_currentsite($site_url,$objbo->getmode());
+ $sitemgr_info =
array_merge($sitemgr_info,$Common_BO->sites->current_site);
+ $sitemgr_info['sitelanguages'] =
explode(',',$sitemgr_info['site_languages']);
$objbo->setsitemgrPreferredLanguage();
+ $objui = new ui;
$page = CreateObject('sitemgr.Page_SO');
***************
*** 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
--- 76,82 ----
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.3.2.1 functions.inc.php,1.6,1.6.2.1 index.php,1.7.2.1,1.7.2.2,
Michael Totschnig <address@hidden> <=
- Prev by Date:
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site/templates/3D-Fantasy draft_transform.inc.php,NONE,1.1.2.1 edit_transform.inc.php,NONE,1.2.2.1 main.tpl,1.3.2.1,1.3.2.2
- Next by Date:
[Phpgroupware-cvs] CVS: sitemgr/modules class.module_administration.inc.php,1.1.2.1,1.1.2.2 class.module_appdir.inc.php,1.1.2.1,1.1.2.2 class.module_bookmarks.inc.php,1.2.2.2,1.2.2.3 class.module_currentsection.inc.php,1.1.2.1,1.1.2.2 class.module_galerie.inc.php,1.1.2.1,1.1.2.2 class.module_html.inc.php,1.1.2.1,1.1.2.2 class.module_lang_block.inc.php,1.1.2.1,1.1.2.2 class.module_news.inc.php,1.2.2.2,1.2.2.3 class.module_sitetree.inc.php,1.1.2.2,1.1.2.3 class.module_toc.inc.php,1.1.2.1,1.1.2.2 class.module_xml.inc.php,1.1.2.1,1.1.2.2
- Previous by thread:
[Phpgroupware-cvs] CVS: sitemgr/sitemgr-site/templates/3D-Fantasy draft_transform.inc.php,NONE,1.1.2.1 edit_transform.inc.php,NONE,1.2.2.1 main.tpl,1.3.2.1,1.3.2.2
- Next by thread:
[Phpgroupware-cvs] CVS: sitemgr/modules class.module_administration.inc.php,1.1.2.1,1.1.2.2 class.module_appdir.inc.php,1.1.2.1,1.1.2.2 class.module_bookmarks.inc.php,1.2.2.2,1.2.2.3 class.module_currentsection.inc.php,1.1.2.1,1.1.2.2 class.module_galerie.inc.php,1.1.2.1,1.1.2.2 class.module_html.inc.php,1.1.2.1,1.1.2.2 class.module_lang_block.inc.php,1.1.2.1,1.1.2.2 class.module_news.inc.php,1.2.2.2,1.2.2.3 class.module_sitetree.inc.php,1.1.2.2,1.1.2.3 class.module_toc.inc.php,1.1.2.1,1.1.2.2 class.module_xml.inc.php,1.1.2.1,1.1.2.2
- Index(es):