-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathSampleDeliveryReport.php
More file actions
33 lines (28 loc) · 1.16 KB
/
Copy pathSampleDeliveryReport.php
File metadata and controls
33 lines (28 loc) · 1.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
/**
* (C) Copyright 1997-2013 hSenid International (pvt) Limited.
* All Rights Reserved.
*
* These materials are unpublished, proprietary, confidential source code of
* hSenid International (pvt) Limited and constitute a TRADE SECRET of hSenid
* International (pvt) Limited.
*
* hSenid International (pvt) Limited retains all title to and intellectual
* property rights in these materials.
*/
include_once '../../lib/sms/SmsDeliveryReport.php';
include_once '../log.php';
ini_set('error_log', 'sms-delivery-report-error.log');
try {
$receiver = new SmsDeliveryReport(); // Create the Receiver object
$destinationAddress = $receiver->getDesAddress();
$timeStamp = $receiver->getTimeStamp();
$requestId = $receiver->getRequestId();
$deliveryStatus = $receiver->getDeliveryStatus();
logFile("Sms delivery report received from TAP : ");
logFile("[ destinationAddress=$destinationAddress, timeStamp=$timeStamp, requestId=$requestId, deliveryStatus=$deliveryStatus ]");
} catch (SmsException $ex) {
//throws when failed delivery report receiving
error_log("ERROR: {$ex->getStatusCode()} | {$ex->getStatusMessage()}");
}
?>