承接 rkr/countries 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

rkr/countries

最新稳定版本:0.1.5

Composer 安装命令:

composer require rkr/countries

包简介

A library to help translating country-names into various standards and to text

README 文档

README

Build Status Latest Stable Version License

The country-codes are copied from umpirsky/country-list. I've only added some code-locators and some translators and removed all those formats not suited for my needs.

Some examples

Get all countries

$provider = new IcuCountryListProvider('en', 'GB');
print_r($provider->getCountries());
Array
(
    [AF] => Afghanistan
    [AX] => Åland Islands
    [AL] => Albania
    [DZ] => Algeria
    [AS] => American Samoa
    [AD] => Andorra
    [AO] => Angola
    [AI] => Anguilla
    (248 more ...)
)

Get the name of a specific country

$provider = new IcuCountryNameLocator('en', 'GB');
echo $provider->getCountry('DE');

Germany

Get all EU-countries:

$provider = new EuCountryProvider('en', 'GB');
print_r($provider->getList());
Array
(
    [BE] => Belgium
    [BG] => Bulgaria
    [CZ] => Czech Republic
    [DK] => Denmark
    [DE] => Germany
    [EE] => Estonia
    [IE] => Ireland
    (22 more ...)
)

统计信息

  • 总下载量: 3.98k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 3
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 3
  • Watchers: 1
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2014-12-04