PHP code example of smsalert-mobi / smsalert-php
1. Go to this page and download the library: Download smsalert-mobi/smsalert-php library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
smsalert-mobi / smsalert-php example snippets
// Send an SMS using SMSAlert's REST API and PHP
$username = "demo"; // Your account username
$apiKey = "api_key_here"; // Your account apiKey from https://smsalert.mobi/settings
$client = new SmsAlert\SmsClient($username, $apiKey);
$messageId = $client->sendSms('0720123456', 'test api');
echo $messageId;
composer