mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-13 17:38:28 +01:00
had to make several changes and cleanups for php3 compatibility
This commit is contained in:
parent
2628c9857c
commit
4b1390eb0f
@ -205,9 +205,10 @@
|
||||
}
|
||||
}
|
||||
|
||||
function addressbook_strip_html($dirty=array())
|
||||
function addressbook_strip_html($dirty = "")
|
||||
{
|
||||
global $phpgw;
|
||||
if ($dirty == ""){$dirty = array();}
|
||||
for($i=0;$i<count($dirty);$i++)
|
||||
{
|
||||
while (list($name,$value) = each($dirty[$i])) {
|
||||
|
@ -34,7 +34,7 @@
|
||||
$p = CreateObject('phpgwapi.Template',PHPGW_APP_TPL);
|
||||
|
||||
$p->set_file(array(
|
||||
'accounts' => 'accounts.tpl',
|
||||
'accounts' => 'accounts.tpl'
|
||||
));
|
||||
$p->set_block('accounts','list','list');
|
||||
$p->set_block('accounts','row','row');
|
||||
|
@ -35,7 +35,7 @@
|
||||
|
||||
$p = CreateObject('phpgwapi.Template',PHPGW_APP_TPL);
|
||||
$p->set_file(array(
|
||||
'groups' => 'groups.tpl',
|
||||
'groups' => 'groups.tpl'
|
||||
));
|
||||
$p->set_block('groups','list','list');
|
||||
$p->set_block('groups','row','row');
|
||||
|
@ -19,7 +19,7 @@
|
||||
|
||||
$admin_tpl = CreateObject('phpgwapi.Template',PHPGW_APP_TPL);
|
||||
$admin_tpl->set_file(array(
|
||||
'admin' => 'index.tpl',
|
||||
'admin' => 'index.tpl'
|
||||
));
|
||||
|
||||
$admin_tpl->set_block('admin','list');
|
||||
|
@ -209,7 +209,7 @@ class calendar extends calendar_
|
||||
$p = CreateObject('phpgwapi.Template',$this->template_dir);
|
||||
$p->set_unknowns('remove');
|
||||
$templates = Array(
|
||||
'link_picture' => 'link_pict.tpl',
|
||||
'link_picture' => 'link_pict.tpl'
|
||||
);
|
||||
$p->set_file($templates);
|
||||
$p->set_block('link_picture','link_pict','link_pict');
|
||||
|
@ -37,7 +37,8 @@
|
||||
{
|
||||
$owner = $phpgw_info['user']['account_id'];
|
||||
$rights = PHPGW_ACL_READ + PHPGW_ACL_ADD + PHPGW_ACL_EDIT + PHPGW_ACL_DELETE + PHPGW_ACL_PRIVATE;
|
||||
$grants[$owner] = $rights;
|
||||
$grants = Array();
|
||||
$grants[$owner] = "$rights";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -34,7 +34,6 @@
|
||||
* This constructor sets the account id, if string is sent, converts to id *
|
||||
* I might move this to the accounts_shared if it stays around *
|
||||
\**************************************************************************/
|
||||
|
||||
function accounts($account_id = '')
|
||||
{
|
||||
global $phpgw, $phpgw_info;
|
||||
@ -110,7 +109,7 @@
|
||||
for ($idx=0; $idx<count($security_equals); $idx++)
|
||||
{
|
||||
$name = $this->id2name(intval($security_equals[$idx]));
|
||||
$this->members[] = Array('account_id' => intval($security_equals[$idx]), 'account_name' => $name);
|
||||
$this->members = Array('account_id' => intval($security_equals[$idx]), 'account_name' => $name);
|
||||
}
|
||||
|
||||
return $this->members;
|
||||
|
@ -566,7 +566,8 @@
|
||||
$sql = "select acl_account, acl_rights from phpgw_acl where acl_appname = '$app' and "
|
||||
. "acl_location in ";
|
||||
$security = "('". $phpgw_info['user']['account_id'] ."'";
|
||||
$my_memberships = $phpgw->accounts->memberships();
|
||||
$myaccounts = CreateObject('phpgwapi.accounts');
|
||||
$my_memberships = $myaccounts->memberships();
|
||||
while($my_memberships && $groups = each($my_memberships))
|
||||
{
|
||||
$group = each($groups);
|
||||
|
@ -80,9 +80,10 @@
|
||||
@param $filter_obj ?
|
||||
@param $showsearch ?
|
||||
*/
|
||||
function show_tpl($sn,$start,$total,$extra, $twidth, $bgtheme,$search_obj=0,$filter_obj=1,$showsearch=1,$yours=0)
|
||||
function show_tpl($sn,$localstart,$total,$extra, $twidth, $bgtheme,$search_obj=0,$filter_obj=1,$showsearch=1,$yours=0)
|
||||
{
|
||||
global $filter, $qfield, $start, $order, $sort, $query, $phpgw, $phpgw_info;
|
||||
$start = $localstart;
|
||||
$tpl = createobject('phpgwapi.Template',PHPGW_TEMPLATE_DIR);
|
||||
$tpl->set_file(array(
|
||||
'nextmatchs' => 'nextmatchs.tpl'
|
||||
|
@ -259,8 +259,8 @@
|
||||
$phpgw->common = CreateObject('phpgwapi.common');
|
||||
$phpgw->hooks = CreateObject('phpgwapi.hooks');
|
||||
$phpgw->auth = CreateObject('phpgwapi.auth');
|
||||
$phpgw->acl = CreateObject('phpgwapi.acl');
|
||||
$phpgw->accounts = CreateObject('phpgwapi.accounts');
|
||||
$phpgw->acl = CreateObject('phpgwapi.acl');
|
||||
$phpgw->session = CreateObject('phpgwapi.sessions');
|
||||
$phpgw->preferences = CreateObject('phpgwapi.preferences');
|
||||
$phpgw->applications = CreateObject('phpgwapi.applications');
|
||||
@ -332,7 +332,7 @@
|
||||
|
||||
/* This will make sure that a user has the basic default prefs. If not it will add them */
|
||||
$phpgw->preferences->verify_basic_settings();
|
||||
|
||||
|
||||
/********* Optional classes, which can be disabled for performance increases *********/
|
||||
while ($phpgw_class_name = each($phpgw_info['flags']))
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user