julien-c / iso3166
ISO 3166-1 alpha-2 mapping
Installs: 2 424 882
Dependents: 2
Suggesters: 0
Security: 0
Stars: 65
Watchers: 6
Forks: 9
Open Issues: 4
This package is not auto-updated.
Last update: 2024-12-13 22:54:38 UTC
README
ISO 3166-1 alpha-2 mapping:
Get Country Name:
echo Iso3166\Codes::country('FR'); // 'France'
Get Phone Code:
echo Iso3166\Codes::phoneCode('FR'); // '33'
Get Continent Name:
echo Iso3166\Codes::continent('EU'); // 'Europa'
Plus one super handy helper:
echo Iso3166\Codes::countrySelector('class', 'name', 'FR');
will output:
<select class="class" name="name"> <option value="AF">Afghanistan</option> ... <option value="FR" selected>France</option> ... </select>