PHPackages                             taghwo/phone-number-validator-formatter-for-nigerian-phone-numbers - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. taghwo/phone-number-validator-formatter-for-nigerian-phone-numbers

ActiveLibrary

taghwo/phone-number-validator-formatter-for-nigerian-phone-numbers
==================================================================

This handles backend validations and formatting of Nigerian phone numbers

v1.01(5y ago)021MITPHPPHP ~7.2

Since Nov 21Pushed 5y ago1 watchersCompare

[ Source](https://github.com/taghwo/nigerian-phone-number-validator-formatters)[ Packagist](https://packagist.org/packages/taghwo/phone-number-validator-formatter-for-nigerian-phone-numbers)[ Docs](https://github.com/taghwo/nigerian-phone-number-validator-formatters)[ RSS](/packages/taghwo-phone-number-validator-formatter-for-nigerian-phone-numbers/feed)WikiDiscussions master Synced yesterday

READMEChangelog (1)Dependencies (4)Versions (2)Used By (0)

\#Installation

```
composer require taghwo/nigerian-phone-number-validator-formatters
```

\#include package in your PHP file

```
 require_once "vendor/autoload.php";
```

```
use Taghwo\PhoneNumber\PhoneNumberRequest;
```

\##Available methods

```
setDigits() accepts single or range of digits(min_range, max_range). ('14') or ('11','14)

```

```
validateWithRange() will validate if phone number supplied falls within range

```

```
validateStrict() throws exception if phone number supplied is === single number in setDigits()

```

```
getCleanNumber() returns clean phone number

```

```
formatToIntPhoneNumber() prefixes 234 on phonenumber if it does not have it

```

```
getPrefix() fetches phonenumber prefix

```

```
splitPhoneNumber() splits phone number into chunks based on criterai supplied, (null, 4)

```

```
setPhoneNumber() Note only use when using the static call on use Taghwo\PhoneNumber\PhoneNumber;

```

\#Usage

example using the class instance
--------------------------------

[](#example-using-the-class-instance)

```
$phonenumber = new PhoneNumberRequest('/--dff/s07000000000');

          $phonenumber
            ->setDigits('11,14')
            ->validateWithRange() ✅
            ->getCleanNumber()//07000000000;✅
            ->formatToIntPhoneNumber()//2347000000000;✅
            ->getPrefix()//070
            ->splitPhoneNumber(null, 3);//[070,000,000,00];
```

using statically
----------------

[](#using-statically)

```
use Taghwo\PhoneNumber\PhoneNumber;
```

```
PhoneNumber::setDigits('14')
            ->setPhoneNumber('/--dff/s07000000000')
            ->validateStrict()//❌ must be 14 chars
            ->getCleanNumber()//0700000000;✅
            ->formatToIntPhoneNumber()//2347000000000;✅
            ->getPrefix()//070
            ->splitPhoneNumber(null, 3);//[070,000,000,00];
```

\#Extra

```
Running quick checks on phone number, returns true and false

```

```
use Taghwo\PhoneNumber\Rule\Check;

$isValid = Check::verifyPhoneNumber('000007060499168');//❌false
$isIntFormat = Check::verifyPhoneNumberIsIntFormat('007060499168');//❌False

```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1998d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/37c4c6797bd0ef2e057dca0c005ce8c38ba4d796ff92e3be010bc4dc825127a9?d=identicon)[Taghwo Millionaire O](/maintainers/Taghwo%20Millionaire%20O)

---

Top Contributors

[![taghwo](https://avatars.githubusercontent.com/u/40868373?v=4)](https://github.com/taghwo "taghwo (14 commits)")

---

Tags

taghwophone-number-validator-formatter-for-nigerian-phone-numbers

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/taghwo-phone-number-validator-formatter-for-nigerian-phone-numbers/health.svg)

```
[![Health](https://phpackages.com/badges/taghwo-phone-number-validator-formatter-for-nigerian-phone-numbers/health.svg)](https://phpackages.com/packages/taghwo-phone-number-validator-formatter-for-nigerian-phone-numbers)
```

###  Alternatives

[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[bacula-web/bacula-web

The open source web based reporting and monitoring tool for Bacula

1537.5k](/packages/bacula-web-bacula-web)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

255.2k](/packages/aedart-athenaeum)[doppar/framework

The Doppar Framework

366.7k8](/packages/doppar-framework)[hardcastle/xrpl_php

PHP SDK / Client for the XRP Ledger

129.7k5](/packages/hardcastle-xrpl-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
