PHP code example of andersevenrud / laravel-frontsms
1. Go to this page and download the library: Download andersevenrud/laravel-frontsms 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/ */
andersevenrud / laravel-frontsms example snippets
use FrontSMS;
function something() {
$result = FrontSMS::send(12345678, 'hello world!');
}
use NotificationChannels\FrontSMS\FrontSMSChannel;
use NotificationChannels\FrontSMS\FrontSMSMessage;
use Illuminate\Notifications\Notification;
class ExampleNotification extends Notification
{
public function via($notifiable)
{
return [FrontSMSChannel::class];
}
public function toFront($notifiable)
{
return FrontSMSMessage::create('12345678', 'Hello world!');
}
}
$ php artisan vendor:publish