phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] CVS: wcm/inc class.bosite.inc.php,1.12,1.13


From: Miles Lott <address@hidden>
Subject: [Phpgroupware-cvs] CVS: wcm/inc class.bosite.inc.php,1.12,1.13
Date: Tue, 26 Feb 2002 23:10:13 -0500

Update of /cvsroot/phpgroupware/wcm/inc
In directory subversions:/tmp/cvs-serv31350/inc

Modified Files:
        class.bosite.inc.php 
Log Message:
Add new config for anon user password; phpGroupWare install location and anon 
user/pass
now set during publish (not hardcoded in template)



Index: class.bosite.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/wcm/inc/class.bosite.inc.php,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -r1.12 -r1.13
*** class.bosite.inc.php        25 Feb 2002 04:03:59 -0000      1.12
--- class.bosite.inc.php        27 Feb 2002 04:10:11 -0000      1.13
***************
*** 205,208 ****
--- 205,213 ----
                function publish($siteid='',$pageid='')
                {
+                       $cfg = CreateObject('phpgwapi.config','wcm');
+                       $cfg->read_repository();
+                       $acct = 
$GLOBALS['phpgw']->accounts->id2name($cfg->config_data['website_account']);
+                       $pass = $cfg->config_data['website_account_passwd'];
+ 
                        if(!$siteid)
                        {
***************
*** 246,249 ****
--- 251,258 ----
                        $tpl->set_block('frame','php_code','php_code');
  
+                       $tpl->set_var('anonusername',$acct ? $acct : 'demo');
+                       $tpl->set_var('anonpassword',$pass ? $pass : 'guest');
+                       $tpl->set_var('phpgwdir',PHPGW_SERVER_ROOT . SEP);
+ 
                        while(list(,$page) = each($this->site['site_pages']))
                        {
***************
*** 261,265 ****
                                $tpl->set_var('right_width',   $site_right ? 
$site_right : '130');
  
!                               $out = "<?php settype(\$site,'string'); \$page 
= array(); \$ele = array(); \$site = '" . $this->site['site_name'] . "'; "
                                        . "\$page = array('name' => '" . 
$page['page_name'] . "', "
                                        . "'version' => '" . 
$page['page_version'] . "', "
--- 270,275 ----
                                $tpl->set_var('right_width',   $site_right ? 
$site_right : '130');
  
!                               $out = "<?php 
\$GLOBALS['phpgw_info']['user']['account_id'] = $acct;"
!                                       . " settype(\$site,'string'); \$page = 
array(); \$ele = array(); \$site = '" . $this->site['site_name'] . "'; "
                                        . "\$page = array('name' => '" . 
$page['page_name'] . "', "
                                        . "'version' => '" . 
$page['page_version'] . "', "




reply via email to

[Prev in Thread] Current Thread [Next in Thread]