[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] CVS: wcm/website main.php,1.3,1.4
From: |
Miles Lott <address@hidden> |
Subject: |
[Phpgroupware-cvs] CVS: wcm/website main.php,1.3,1.4 |
Date: |
Sun, 10 Feb 2002 13:21:13 -0500 |
Update of /cvsroot/phpgroupware/wcm/website
In directory subversions:/tmp/cvs-serv7987/website
Modified Files:
main.php
Log Message:
Fixup for display in website/main.php; add selection of header/footer based on
element
type and availability
Index: main.php
===================================================================
RCS file: /cvsroot/phpgroupware/wcm/website/main.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** main.php 8 Feb 2002 15:23:11 -0000 1.3
--- main.php 10 Feb 2002 18:21:11 -0000 1.4
***************
*** 23,27 ****
$wcm = CreateObject('wcm.bowcm','phpgw');
! _debug_array($wcm->site);
define('SITE_ROOT', PHPGW_SERVER_ROOT . SEP . 'wcm' . SEP . 'website' .
SEP . 'templates');
--- 23,29 ----
$wcm = CreateObject('wcm.bowcm','phpgw');
! $elements = CreateObject('wcm.boelement');
!
! //_debug_array($wcm->site['site_pages'][0]);
define('SITE_ROOT', PHPGW_SERVER_ROOT . SEP . 'wcm' . SEP . 'website' .
SEP . 'templates');
***************
*** 40,56 ****
/* check expiration of each page and element */
! $GLOBALS['phpgw']->template->set_var('left_content','LEFT');
! $GLOBALS['phpgw']->template->set_var('mid_content','MIDDLE');
! $GLOBALS['phpgw']->template->set_var('right_content','RIGHT');
!
! echo '
! <html>
! <head>
! </head>
! ';
$GLOBALS['phpgw']->template->pfp('out','frame');
-
- echo '
- </html>'
?>
--- 42,70 ----
/* check expiration of each page and element */
! $header_data =
$elements->read($wcm->site['site_pages'][0]['page_header']);
! $header = $header_data['element_source'];
! $GLOBALS['phpgw']->template->set_var('header',$header ? $header :
'<html><head>HEADER</head><body>');
!
! $footer_data =
$elements->read($wcm->site['site_pages'][0]['page_footer']);
! $footer = $footer_data['element_source'];
! $GLOBALS['phpgw']->template->set_var('footer',$footer ? $footer :
'FOOTER</body></html>');
!
! $left = $mid = $right = '';
! while(list($key,$val) =
@each($wcm->site['site_pages'][0]['page_elements']['left']))
! {
! $left .= $val['element_source'];
! }
! while(list($key,$val) =
@each($wcm->site['site_pages'][0]['page_elements']['mid']))
! {
! $mid .= $val['element_source'];
! }
! while(list($key,$val) =
@each($wcm->site['site_pages'][0]['page_elements']['right']))
! {
! $right .= $val['element_source'];
! }
! $GLOBALS['phpgw']->template->set_var('left_content',$left ? $left :
'LEFT');
! $GLOBALS['phpgw']->template->set_var('mid_content',$mid ? $mid :
'MIDDLE');
! $GLOBALS['phpgw']->template->set_var('right_content',$right ? $right :
'RIGHT');
$GLOBALS['phpgw']->template->pfp('out','frame');
?>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] CVS: wcm/website main.php,1.3,1.4,
Miles Lott <address@hidden> <=
- Prev by Date:
[Phpgroupware-cvs] CVS: wcm/inc class.boelement.inc.php,1.2,1.3 class.bowcm.inc.php,1.3,1.4 class.soelement.inc.php,1.6,1.7 class.sopage.inc.php,1.5,1.6 class.sosite.inc.php,1.4,1.5 class.uielement.inc.php,1.3,1.4 class.uipage.inc.php,1.6,1.7
- Next by Date:
[Phpgroupware-cvs] CVS: wcm/templates/default page_form.tpl,1.4,1.5
- Previous by thread:
[Phpgroupware-cvs] CVS: wcm/inc class.boelement.inc.php,1.2,1.3 class.bowcm.inc.php,1.3,1.4 class.soelement.inc.php,1.6,1.7 class.sopage.inc.php,1.5,1.6 class.sosite.inc.php,1.4,1.5 class.uielement.inc.php,1.3,1.4 class.uipage.inc.php,1.6,1.7
- Next by thread:
[Phpgroupware-cvs] CVS: wcm/templates/default page_form.tpl,1.4,1.5
- Index(es):