Skip to content

Latest commit

 

History

History
45 lines (37 loc) · 743 Bytes

README.md

File metadata and controls

45 lines (37 loc) · 743 Bytes

NG

PHP Class containing Nigeria's Data

Usage

Install package composer require jajo/ng

Get States

<?php 
use Jajo\NG;

$ng = new NG();
$ng->states;

Get Local Government Areas

<?php 
use Jajo\NG;

$ng = new NG();
$ng->getLGA( 'Lagos' );

Get State Capital

<?php 
use Jajo\NG;

$ng = new NG();
$ng->getCapital( 'Lagos' );

Get LGA or Capital owned by a state

<?php 
use Jajo\NG;

$ng = new NG();
$ng->getStateBy( 'capital', 'Ikeja' );
$ng->getStateBy( 'lga', 'Ohafia' );

Contributing

I would love to extend this class to a database of Nigerian data, I had to start somewhere. Any form of contribution is welcomed!

Finally

Much love from Naija!!! 🇳🇬 🇳🇬