[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] folders/inc class.uifolders.inc.php,1.2,1.3
From: |
Philipp Kamps <address@hidden> |
Subject: |
[Phpgroupware-cvs] folders/inc class.uifolders.inc.php,1.2,1.3 |
Date: |
Mon, 17 Nov 2003 17:32:33 +0000 |
Update of /cvsroot/phpgroupware/folders/inc
In directory subversions:/tmp/cvs-serv22055/inc
Modified Files:
class.uifolders.inc.php
Log Message:
workaround for a bug with IE. More hardcoded values removed.
Index: class.uifolders.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/folders/inc/class.uifolders.inc.php,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** class.uifolders.inc.php 7 Nov 2003 17:02:34 -0000 1.2
--- class.uifolders.inc.php 17 Nov 2003 17:32:30 -0000 1.3
***************
*** 1,18 ****
<?php
!
/**************************************************************************\
! * phpGroupWare API - uifolders
*
! * This file based on PHP3 TreeMenu
*
! * (c)2003 Philipp Kamps <address@hidden> *
! *
------------------------------------------------------------------------ *
! * This is not part of phpGroupWare, but is used by phpGroupWare.
*
! * http://www.phpgroupware.org/
*
! * This program is free software; you can redistribute it and/or modify
it *
! * under the terms of the GNU General Public License as published by the
*
! * Free Software Foundation; either version 2 of the License, or (at
your *
! * option) any later version.
*
!
\**************************************************************************/
!
! /* $Id$ */
!
class uifolders
--- 1,11 ----
<?php
! /**
! * folders module
! * @author Philipp Kamps <address@hidden>
! * @copyright Copyright (C) 2003 Free Software Foundation http://www.fsf.org/
! * @license http://www.fsf.org/licenses/gpl.html GNU General Public License
! * @package folders
! * @version $Id$
! */
class uifolders
***************
*** 32,55 ****
function enableFolders()
{
! $GLOBALS['HTTP_SESSION_VARS']['folders']['mode'] =
'enabled';
! Header('Location: '.$GLOBALS['HTTP_REFERER']);
}
function disableFolders()
{
! $GLOBALS['HTTP_SESSION_VARS']['folders']['mode'] =
'disabled';
! Header('Location: '.$GLOBALS['HTTP_REFERER']);
! }
!
! function get_folderMode()
! {
! if ( $GLOBALS['HTTP_SESSION_VARS']['folders']['mode']
== 'enabled' )
! {
! return 'enabled';
! }
! else
! {
! return 'disabled';
! }
}
--- 25,36 ----
function enableFolders()
{
!
$_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['mode'] = 'enabled';
! Header('Location:
'.$_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['link']);
}
function disableFolders()
{
!
$_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['mode'] =
'disabled';
! Header('Location:
'.$_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['link']);
}
***************
*** 79,90 ****
}
! function get_switchlink($mode)
{
! // hardcoded path :-(
! $this->t->set_root(PHPGW_SERVER_ROOT .
'/folders/templates/default/');
$this->t->set_file(array('helpers_t' => 'helpers.tpl'));
$this->t->set_block('helpers_t','link');
! if ($mode == 'enabled')
{
$var['linkvalue'] =
$GLOBALS['phpgw']->link('/index.php','menuaction=folders.uifolders.disablefolders');
--- 60,82 ----
}
! function get_switchlink()
{
! /* workaround: IE doesn't set the PHP referer variable
*/
! if ($GLOBALS['SSL_VERSION_LIBRARY'])
! {
! $httpMode = 'https://';
! }
! else
! {
! $httpMode = 'http://';
! }
!
$_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['link'] =
$httpMode.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];
! /* end of workaround */
!
! $this->t->set_root(PHPGW_SERVER_ROOT .
'/folders/templates/default/'); // hardcoded path :-(
$this->t->set_file(array('helpers_t' => 'helpers.tpl'));
$this->t->set_block('helpers_t','link');
! if
($_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['mode'] ==
'enabled')
{
$var['linkvalue'] =
$GLOBALS['phpgw']->link('/index.php','menuaction=folders.uifolders.disablefolders');
***************
*** 101,104 ****
return $this->t->get_var('out');
}
- }
--- 93,107 ----
return $this->t->get_var('out');
}
+ function get_folderMode()
+ {
+ if (
$_SESSION['phpgw_session']['phpgw_app_sessions']['folders']['mode'] ==
'enabled' )
+ {
+ return 'enabled';
+ }
+ else
+ {
+ return 'disabled';
+ }
+ }
+ }
\ No newline at end of file
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] folders/inc class.uifolders.inc.php,1.2,1.3,
Philipp Kamps <address@hidden> <=