Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/julien-c/iso3166

ISO 3166-1 alpha-2 mapping
https://github.com/julien-c/iso3166

Last synced: about 16 hours ago
JSON representation

ISO 3166-1 alpha-2 mapping

Awesome Lists containing this project

README

        

iso3166
=======

ISO 3166-1 alpha-2 mapping:

Get Country Name:
```php
echo Iso3166\Codes::country('FR');
// 'France'
```

Get Phone Code:
```php
echo Iso3166\Codes::phoneCode('FR');
// '33'
```

Get Continent Name:
```php
echo Iso3166\Codes::continent('EU');
// 'Europa'
```

Plus one super handy helper:

```php
echo Iso3166\Codes::countrySelector('class', 'name', 'FR');
```

will output:

```html

Afghanistan
...
France
...

```