Package Data | |
---|---|
Maintainer Username: | tariq86 |
Package Create Date: | 2016-07-29 |
Package Last Update: | 2022-04-05 |
Home Page: | |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-20 03:01:15 |
Package Statistics | |
---|---|
Total Downloads: | 13,276 |
Monthly Downloads: | 40 |
Daily Downloads: | 2 |
Total Stars: | 7 |
Total Watchers: | 3 |
Total Forks: | 1 |
Total Open Issues: | 0 |
Country List is a package for Laravel 4 & 5, which lists all countries with names and ISO 3166-1 codes in all languages and data formats.
composer require tariq86/country-list
app/config/app.php
and add the service provider to your providers
array. 'providers' => [
// Other providers...
Tariq86\CountryList\CountryListServiceProvider::class,
]
Now add the alias.
'aliases' => [
// Other aliases...
'Countries' => Tariq86\CountryList\CountryListFacade::class
]
\App::getLocale()
)Get all countries
Route::get('/', function()
{
return Countries::getList('en', 'json');
});
Get one country
Route::get('/', function()
{
return Countries::getOne('RU', 'en');
});