PHP code example of firmantr3 / laravel-sms
1. Go to this page and download the library: Download firmantr3/laravel-sms 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/ */
firmantr3 / laravel-sms example snippets
return [
'providers': [
// Other Providers above
Firmantr3\Sms\SmsServiceProvider::class,
],
];
use Firmantr3\Sms\Facade\Sms;
// send using default sms channel
Sms::text('test')->phone('081138702880')->send();
// send using particular sms channel
$sms = Sms::channel('zenziva')->text('test text zenziva')->phone('081138702880');
$sms->send();
// debug response data
print_r($sms->getResponse());
bash
php artisan vendor:publish --provider=Firmantr3\\Sms\\SmsServiceProvider