PHPackages                             emma/internationalization - 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. [Localization &amp; i18n](/categories/localization)
4. /
5. emma/internationalization

ActiveLibrary[Localization &amp; i18n](/categories/localization)

emma/internationalization
=========================

A PHP 7.0+ internationalization library and services for getting all the world countries, country states, country's currency/currencies, symbols, locale and languages. It also includes: number formatter, decimal formatter and currency formatter. currency formatter by country name, isoAlphaCode2 or isoAlphaCode3.

v1.0.1(2y ago)0521GPL-2.0-onlyPHPPHP &gt;=7.0

Since May 24Pushed 2y ago1 watchersCompare

[ Source](https://github.com/debascoguy/intlCountries)[ Packagist](https://packagist.org/packages/emma/internationalization)[ RSS](/packages/emma-internationalization/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (1)

intlCountries
=============

[](#intlcountries)

A PHP 7.0+ internationalization library and services for getting all the

- world countries,
- country states,
- country's currency/currencies,
- symbols, locale and
- languages.

It also includes:

- Number Formatter,
- Decimal Formatter and
- Currency Formatter : currency formatter by country name, isoAlphaCode2 or isoAlphaCode3.

I am not going to bore you with lots of write-up to justify why you should or should not use this library as I strongly believe nobody says no to problem solving tools. So, here are the example as it can be used to solve internationalization problems:

```
use Emma\Countries\Countries;

//VERY IMPORTANT - All function that returns an object also has there corresponding function that returns an array data set.

/**
* GET ALL
*/
//Get all - COUNTRIES
$countries = Countries::getCountryRepository()->findAllCountry();

//Get all - CURRENCIES - countries and there currency(s) information
$currencies = Countries::getCurrencyRepository()->findAllCountryAndCurrency();

//Get all - LANGUAGE - locales of all countries. Data incliudes: isoAlphaCode2, isoAlphaCode3, locales, defaultLocale, language of countries.
$locales = Countries::getLocaleRepository()->findAllLocales();

/**
* FIND SOMETHING SPECIFIC
*/
//Get a particular country locales information - By countryName OR country isoAlphaCode2 OR country isoAlphaCode2.
$countryNameORisoAlphaCode2ORisoAlphaCode2 = 'US'; //OR USD OR United States of America
$countryLocales = Countries::getLocaleRepository()->findLocale(string $countryNameORisoAlphaCode2ORisoAlphaCode2)

//Get a particular country information - By countryName OR country isoAlphaCode2 OR country isoAlphaCode2.
//Data includes: name, all states in that country, currencies, default_country of that country, etc...
$countryNameORisoAlphaCode2ORisoAlphaCode2 = 'US'; //OR USD OR United States of America
$countryInformation = (Countries::getCountryRepository()->findCountry($countryNameORisoAlphaCode2ORisoAlphaCode2));

//Get a particular country currency detailed information. For example:
$code = 'NGN';
$currency = (Countries::getCurrencyRepository()->findCurrencyDetails($code));

/**
* FORMATTERS
*/
//Format Currency using countryName OR country isoAlphaCode2 OR country isoAlphaCode2
echo $formatedAmount = Countries::formatCurrencyByCountry(5.0, 'NG');
echo $formatedAmount = Countries::formatCurrencyByCountry(5.0, 'NGA');
echo $formatedAmount = Countries::formatCurrencyByCountry(5.0, 'Nigeria');

//Similarly format Decimal Number By countryName OR country isoAlphaCode2 OR country isoAlphaCode2
echo $formatedAmount = Countries::formatDecimalByCountry(5.0, 'NG');
echo $formatedAmount = Countries::formatDecimalByCountry(5.0, 'NGA');
echo $formatedAmount = Countries::formatDecimalByCountry(5.0, 'Nigeria');

//VERY IMPORTANT - All function that returns an object also has there corresponding function that returns an array data set.
```

If you check the `Countries` class, there are lots functions you can use for so many different internationalization. The example above are a few of how useful this library is to you. :)

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity40

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

Every ~3 days

Total

2

Last Release

1085d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/17ecf1e99357556e97438ed0d7edbabada5380ff58e4a6a49cda3521f5a15637?d=identicon)[debascoguy](/maintainers/debascoguy)

---

Top Contributors

[![debascoguy](https://avatars.githubusercontent.com/u/12888833?v=4)](https://github.com/debascoguy "debascoguy (3 commits)")

### Embed Badge

![Health badge](/badges/emma-internationalization/health.svg)

```
[![Health](https://phpackages.com/badges/emma-internationalization/health.svg)](https://phpackages.com/packages/emma-internationalization)
```

###  Alternatives

[symfony/translation

Provides tools to internationalize your application

6.6k836.5M2.1k](/packages/symfony-translation)[nesbot/carbon

An API extension for DateTime that supports 281 different languages.

169661.4M4.8k](/packages/nesbot-carbon)[joedixon/laravel-translation

A tool for managing all of your Laravel translations

717911.4k11](/packages/joedixon-laravel-translation)[illuminate/translation

The Illuminate Translation package.

6936.4M495](/packages/illuminate-translation)[lajax/yii2-translate-manager

Translation management extension for Yii 2

227578.8k13](/packages/lajax-yii2-translate-manager)[larswiegers/laravel-translations-checker

Make sure your laravel translations are checked and are included in all languages.

256423.2k2](/packages/larswiegers-laravel-translations-checker)

PHPackages © 2026

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