PHP Classes

PHP SMSC.ua Message Sender: Send SMS, MMS, EMail, Viber, Voicemail with SMSC

Recommend this page to a friend!
  Info   View files Documentation   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 145 All time: 9,121 This week: 112Up
Version License PHP version Categories
smsc-ua-sms-sender 1.0.0The PHP License5.5Email, PHP 5, Wireless and Mobile, Li...
Description 

Author

This class can send SMS, MMS, EMail, Viber, Voicemail with SMSC.

It extends the CakePHP component and can send HTTP requests to the SMSC.UA API on behalf of given user and password to send messages to the different supported medium.

The class returns the API response to the calling application.

Picture of Roman Kozin
  Performance   Level  
Name: Roman Kozin is available for providing paid consulting. Contact Roman Kozin .
Classes: 7 packages by
Country: Ukraine Ukraine
Age: 28
All time rank: 274548 in Ukraine Ukraine
Week rank: 312 Up4 in Ukraine Ukraine Up
Innovation award
Innovation award
Nominee: 3x

Winner: 2x

Documentation

How to install this package?

composer require kield-01/smsc-ua-sms-sender dev-master to use current version

What You need to have to use this package?

  • CakePHP 3.3.x

After You require this package, it will install fabpot/goutte package

How to set up this component?

There is 2 options, how to initialize

Option 1

Set up credentials key in config/app.php:

    'smsc_ua' => [
        'login' => '__LOGIN__',
        'psw' => '__PASSWORD__'
    ]

Option 2

Set up credentials after loading component:

    use Cake\Controller\Component\SmscUaComponent;

    /
    * Class X
    *
    * @property SmscUaComponent $SmscUa
    /
    class X extends AppController
    {
    
        public function initialize(){
               $this->loadComponent('SmscUa');
               
               $this->SmscUa
                   ->setLogin('__LOGIN__')
                   ->setPassword('__PASSWORD__');
                   
                /OR/
                
                $this->SmscUa
                    ->setArgument('login', '__LOGIN__')
                    ->setArgument('psw', '__PASSWORD__');
        }
        
    }

API

/Allows You to add one number to current numbers list/
$this->SmscUa->setNumbers('380666666666');

/Allows You to add bulk to current numbers list/
$this->SmscUa->setNumbers(['380666666666', '380666666667']);

/Allows You to set message Text/
$this->SmscUa->setMessageBody('Random text');

/Allows You to change Response format/
$this->SmscUa->setResponseFormat('string'); // Response as string data
$this->SmscUa->setResponseFormat('digits'); // Response as digits, separated by ','
$this->SmscUa->setResponseFormat('xml');    // Response as XML Document
$this->SmscUa->setResponseFormat('json');   // Response as JSON Object

/Sending methods/
$this->SmscUa->sendPlainTextSMS(); // Sending simple SMS

  Files folder image Files  
File Role Description
Files folder imagedata (1 file)
Files folder imagesrc (1 directory)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files  /  data  
File Role Description
  Accessible without login Plain text file rules.php Aux. Auxiliary script

  Files folder image Files  /  src  
File Role Description
Files folder imageController (1 directory)

  Files folder image Files  /  src  /  Controller  
File Role Description
Files folder imageComponent (1 file)

  Files folder image Files  /  src  /  Controller  /  Component  
File Role Description
  Plain text file SmscUaComponent.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:145
This week:0
All time:9,121
This week:112Up