Download the PHP package kenyalang/countries without Composer
On this page you can find all versions of the php package kenyalang/countries. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download kenyalang/countries
More information about kenyalang/countries
Files in kenyalang/countries
Package countries
Short Description A package to get list of countries
License MIT
Homepage https://github.com/kenyalang/countries
Informations about the package countries
A package to get list of countries
Installation
You can install the package via composer:
To publish the config
file, you can use the following command:
Usage
Run the migrations to create and populate the countries
and states
table.
By default, the countries
will be inactive. To enable them update your .env
.
To manually enable a country, you may query the desired country and use the activate
function.
To disable a country, you may query the desired country and use the deactivate
function.
To query only active countries, use the active
scope.
Add the following trait to your model to use the countries
and states
table:
To get the locale of a model use the withLocale
scope:
Testing
Changelog
Please see CHANGELOG for more information on what has changed recently.
Credits
The list of countries was taken from here. Do check it out.
License
The MIT License (MIT). Please see License File for more information.
All versions of countries with dependencies
spatie/laravel-package-tools Version ^1.9.2
illuminate/contracts Version ^9.0