PHP code example of okorneliuk / symfony-websms-notifier

1. Go to this page and download the library: Download okorneliuk/symfony-websms-notifier 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/ */

    

okorneliuk / symfony-websms-notifier example snippets


use Okorneliuk\Symfony\NotifierBridge\WebSms\WebSmsOptions;
use Symfony\Component\Notifier\Message\SmsMessage;

$options = (new WebSmsOptions)
    ->contentCategory('informational')
    ->maxSmsPerMessage(2)
    ->senderAddressType('alphanumeric')
    ->validityPeriod(300);

$message = new SmsMessage('+436991234567', 'Hello!', 'MyCompany', $options);
$texter->send($message);