PHP Classes

MSISDN PHP Library: Validate and find the operator of a phone number

Recommend this page to a friend!
  Info   View files Documentation   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog (1)    
Last Updated Ratings Unique User Downloads Download Rankings
2021-11-28 (6 months ago) RSS 2.0 feedNot yet rated by the usersTotal: 78 All time: 9,880 This week: 139Up
Version License PHP version Categories
msisdn 1.0.0BSD License5PHP 5, Wireless and Mobile, Validation
Description Author

This class can validate and find the operator of a phone number.

It takes a telephone MSISDN number and checks if it is valid.

The class can also determine if the number is of known telephone company operator company.

Innovation Award
PHP Programming Innovation award nominee
November 2021
Number 6
MSISDN is a number that is useful to identify a phone number from any country in the world.

This class can determine if a phone number is of a given operator company.

Manuel Lemos
Picture of Allan Kibet
Name: Allan Kibet <contact>
Classes: 4 packages by
Country: United Kingdom
Age: ???
All time rank: 2484115 in United Kingdom
Week rank: 161 Up5 in United Kingdom Up
Innovation award
Innovation award
Nominee: 2x

Winner: 1x

Details

msisdn

This is a basic PHP 7 package that basically enforces the standard number format of 2547 prrefix of Kenyan based mobile numbers. The clean method also checks for the validity of an MSISDN number if given as 07XX, 7XX or 2547XX formats. Prefixes are updated courtesy of https://en.wikipedia.org/wiki/Telephone_numbers_in_Kenya

Installation

Download the package zip, extract and run

composer install

Alternatively run:

composer require allan/msisdn

Examples

Get Channel

use Msisdn\Utility;
include 'vendor/autoload.php';

var_dump(Utility::channel(254720000000)); // string(9) "SAFARICOM"

Clean MSISDN

use Msisdn\Utility;
include 'vendor/autoload.php';

var_dump(Utility::clean("0720000000")); // int(254720000000)
  Files folder image Files  
File Role Description
Files folder imagesrc (1 directory)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file composer.lock Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation

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

  Files folder image Files  /  src  /  Msisdn  
File Role Description
  Plain text file Utility.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:78
This week:0
All time:9,880
This week:139Up
For more information send a message to info at phpclasses dot org.