Should fix this for GLOBALS

This commit is contained in:
Miles Lott 2001-11-28 03:42:56 +00:00
parent 86adabb752
commit 1ebc3e04ba
2 changed files with 7 additions and 12 deletions

View File

@ -14,12 +14,12 @@
$contacts = CreateObject('phpgwapi.contacts');
if(intval($GLOBALS['new_owner'])==0)
if(intval($GLOBALS['HTTP_POST_VARS']['new_owner'])==0)
{
$contacts->delete_all(intval($GLOBALS['account_id']));
$contacts->delete_all(intval($GLOBALS['HTTP_POST_VARS']['account_id']));
}
else
{
$contacts->change_owner(intval($GLOBALS['account_id']),intval($GLOBALS['new_owner']));
$contacts->change_owner(intval($GLOBALS['HTTP_POST_VARS']['account_id']),intval($GLOBALS['HTTP_POST_VARS']['new_owner']));
}
?>

View File

@ -12,19 +12,14 @@
/* $Id$ */
// Delete all records for a user
if (floor(phpversion()) == 4)
{
global $account_id, $new_owner;
}
$cal = CreateObject('calendar.bocalendar');
if(intval($new_owner)==0)
if(intval($GLOBALS['HTTP_POST_VARS']['new_owner'])==0)
{
$cal->delete_calendar(intval($account_id));
$cal->delete_calendar(intval($GLOBALS['HTTP_POST_VARS']['account_id']));
}
else
{
$cal->change_owner(intval($account_id),intval($new_owner));
$cal->change_owner(intval($GLOBALS['HTTP_POST_VARS']['account_id']),intval($GLOBALS['HTTP_POST_VARS']['new_owner']));
}
?>