From 9b8b74f6feeb99e0222717f0e1ed2f6e51f7b55b Mon Sep 17 00:00:00 2001 From: Tony Mack Date: Thu, 5 May 2011 15:05:35 -0400 Subject: [PATCH] call NotifyPersons() using the admin account instead for the client's acocunt --- planetlab/common/actions.php | 7 ++++--- planetlab/sites/join_request.php | 5 +++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/planetlab/common/actions.php b/planetlab/common/actions.php index 7f751b0..dd6a661 100644 --- a/planetlab/common/actions.php +++ b/planetlab/common/actions.php @@ -5,7 +5,8 @@ require_once 'plc_login.php'; // Get session and API handles require_once 'plc_session.php'; -global $plc, $api; +require_once 'plc_api.php'; +global $plc, $api, $adm; //print header require_once 'plc_drupal.php'; @@ -636,7 +637,7 @@ Our support team will be glad to answer any question that you might have. } } if ($success) { - $api->NotifyPersons($notify_person_ids,$notify_subject,$notify_body); + $adm->NotifyPersons($notify_person_ids,$notify_subject,$notify_body); drupal_set_message ("Deleted $counter person(s)"); } else @@ -676,7 +677,7 @@ Our support team will be glad to answer any question that you might have. } } if ($success) { - $api->NotifyPersons($notify_person_ids,$notify_subject,$notify_body); + $adm->NotifyPersons($notify_person_ids,$notify_subject,$notify_body); drupal_set_message ("Added $counter person(s)"); } else diff --git a/planetlab/sites/join_request.php b/planetlab/sites/join_request.php index 07b9885..f0b5562 100644 --- a/planetlab/sites/join_request.php +++ b/planetlab/sites/join_request.php @@ -9,7 +9,8 @@ require_once 'plc_login.php'; // Get session and API handles require_once 'plc_session.php'; -global $plc, $api; +require_once 'plc_api.php'; +global $plc, $api, $adm; // Print header require_once 'plc_drupal.php'; @@ -175,7 +176,7 @@ EOF; PLC_MAIL_SUPPORT_ADDRESS); $subject="Site registration for " . $site['name'] . " has been approved by " . PLC_NAME; - $api->NotifyPersons(array($pi_id),$subject,$body); + $adm->NotifyPersons(array($pi_id),$subject,$body); } -- 2.43.0