sameer-shelavale / php-countries-array

PHP array of countries with ISO_3166-1, ISO_3166-2 and ISD codes
31 stars 21 forks source link

Kosovo not listed #7

Closed paulboenisch closed 5 years ago

paulboenisch commented 6 years ago

Add Kosovo to country list "XK" => array( 'alpha2'=>'XK', 'alpha3'=>'KOS', 'num'=>'383', 'isd'=> '383', "name" => "Kosovo", "continent" => "Europe", ),

terrymun commented 6 years ago

I am conflicted about this: on one hand, XK is a user-assigned code that is not reserved for any country according to ISO 3166-1 / ISO 3166-2, which this plugin claims to be compliant with:

User-assigned code elements are codes at the disposal of users who need to add further names of countries, territories, or other geographical entities to their in-house application of ISO 3166-1, and the ISO 3166/MA will never use these codes in the updating process of the standard.

If XK is to be added, then other user-assigned codes will have to be added, such as QZ, XN, XU, XV, XX.

paulboenisch commented 6 years ago

Perhaps creating an separate branch + alias for packgist would be an option?

sameer-shelavale commented 6 years ago

I think we should add one more parameter in the functions named 'iso' with default value to true. However if it is false, it can return non-iso country records as well. What do you think ?

paulboenisch commented 6 years ago

take a look at my fork: https://github.com/paulboenisch/php-countries-array/commits/master

it does it like: $countries = CountriesArray::iso(false)->get();

sameer-shelavale commented 5 years ago

Thank you I have merged your PR.