spacha / finnish-zips
Tool for handling finnish zips in Laravel
Requires
Requires (Dev)
- mockery/mockery: ^1.1
- orchestra/testbench: ~3.0
- phpunit/phpunit: ~7.0
- sempro/phpunit-pretty-print: ^1.0
This package is auto-updated.
Last update: 2024-04-18 12:50:29 UTC
README
This is where your description should go. Take a look at contributing.md to see a to do list.
Installation
Via Composer
$ composer require spacha/finnish-zips
Add the service provider and the facade to config/app.php
.
Spacha\FinnishZips\FinnishZipsServiceProvider::class, // ... 'FinnishZips' => Spacha\FinnishZips\Facades\FinnishZips::class,
Usage
After you have installed the package and also set up the service provider and facade, you can start using it right away.
use FinnishZips;
Basic Usage
You can get the area name for given zip code easily. You can pass the code either as integer
or numeric string
.
echo FinnishZips::getArea(00100); // => "PK-seutu" echo FinnishZips::getArea('90520'); // => "Oulun seutu"
You can also get a numeric key specific for the area. It can be useful when it's used in computing.
echo FinnishZips::getAreaKey('90520'); // => 7
Contributing
Please see contributing.md for details and a todolist.
Security
If you discover any security related issues, please email miikasikala96@gmail.com instead of using the issue tracker.
Credits
License
license. Please see the license file for more information.