Revert "Revert "Revert "Update and rename Textmarketer.php to Smsit.class.php"""
This reverts commit 063bd4e430
.
pull/80/head
parent
063bd4e430
commit
b8f25384b2
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
namespace psm\Txtmsg;
|
namespace psm\Txtmsg;
|
||||||
|
|
||||||
class Smsit extends Core {
|
class Textmarketer extends Core {
|
||||||
// =========================================================================
|
// =========================================================================
|
||||||
// [ Fields ]
|
// [ Fields ]
|
||||||
// =========================================================================
|
// =========================================================================
|
||||||
|
@ -39,16 +39,15 @@ class Smsit extends Core {
|
||||||
public $successcount = 0;
|
public $successcount = 0;
|
||||||
|
|
||||||
public function sendSMS($message) {
|
public function sendSMS($message) {
|
||||||
// http://www.smsit.dk/api/sendSms.php?apiKey=[KEY]x&senderId=[AFSENDER]&mobile=[MOBILNUMMER]&message=[BESKED]
|
|
||||||
// Use USERNAME as API KEY, password not needed
|
$textmarketer_url = "https://api.textmarketer.co.uk/gateway/";
|
||||||
$textmarketer_url = "http://www.smsit.dk/api/sendSms.php";
|
|
||||||
$textmarketer_data = urlencode( $message );
|
$textmarketer_data = urlencode( $message );
|
||||||
$textmarketer_origin = urlencode( 'SERVERALERT' );
|
$textmarketer_origin = urlencode( 'SERVERALERT' );
|
||||||
|
|
||||||
|
|
||||||
foreach( $this->recipients as $phone ){
|
foreach( $this->recipients as $phone ){
|
||||||
|
|
||||||
$URL = $textmarketer_url."?apiKey=" . $this->username . "&mobile=" . $phone . "&message=" . $textmarketer_data . "&senderId=" . $textmarketer_origin;
|
$URL = $textmarketer_url."?username=" . $this->username . "&password=" . $this->password . "&to=" . $phone . "&message=" . $textmarketer_data . "&orig=" . $textmarketer_origin;
|
||||||
|
|
||||||
$result = file_get_contents( $URL );
|
$result = file_get_contents( $URL );
|
||||||
|
|
Loading…
Reference in New Issue