PHP Classes

File: sendMultiMsg.php

Recommend this page to a friend!
  Classes of Leader   Sending SMS messages   sendMultiMsg.php   Download  
File: sendMultiMsg.php
Role: Example script
Content type: text/plain
Description: send multi msg to multi mobile number
Class: Sending SMS messages
Send SMS messages using the Doo.ae API
Author: By
Last change:
Date: 10 years ago
Size: 1,919 bytes
 

Contents

Class file image Download
<?php
include("includeSettings.php"); //Include this file to get the general settings
$mobile = ""; //Your mobile number, as registered in Doo.ae.
$password = ""; //Your password, as registered in Doo.ae.
$sender = "sms Msg"; //Message sender, will be encoded to urlencode automatically
$numbers = ""; //the mobile number or set of mobiles numbers that the SMS message will be sent to them, each number must be in international format, without zeros or symbol (+), and separated from others by the symbol (,).
                                                                //Note: numbers count must be equal to messages count in the msgKey
$msg = "Welcome to (1)¡ your subscription will ends on (2)"; //Message Template
$timeSend = "0"; //Determine the send time, 0 means send now
                                                                //Standard format hh:mm:ss
$dateSend = "0"; //Determine the send date, 0 means send now
                                                                //Standard format mm/dd/yyyy
$resultType = 0; //This variable determine the type of the result
                                                                //0: Returns API result as a number.
                                                                //1: Returns API result as meaningful text.
                                                               
$msgKey = "(1),*,mohammad,@,(2), *,12/10/2022***(1),*,Ahmad,@,(2),*,10/10/2022"; //The set of values that will replace the symbols in the template message text
                                                                /*
                                                                Symbols Definition:
                                                                (1), (2)…: the symbols where the values will be replaced with it.
                                                                *: separate between the symbol and the value that will replace it.
                                                                @: separate between each definition of the symbol and its value.
                                                                ***: separate between each SMS definitions.
                                                                */

//Call sendStatus function to check Sending Status
echo $sendPort->sendSMSWK($mobile, $password, $numbers, $sender, $msg, $msgKey, $timeSend, $dateSend, $resultType);
?>