Skip to content

Instantly share code, notes, and snippets.

@sumanthkumarc
Last active June 3, 2023 22:13
Show Gist options
  • Save sumanthkumarc/3204c761eaa1646f3a4fd6cb1cf99e7c to your computer and use it in GitHub Desktop.
Save sumanthkumarc/3204c761eaa1646f3a4fd6cb1cf99e7c to your computer and use it in GitHub Desktop.
EU (European country code and names list) in PHP array format
<?php
function get_eu_countries() {
$countries = [];
$countries['AT'] = ['name' => 'Austria',];
$countries['BE'] = ['name' => 'Belgium',];
$countries['BG'] = ['name' => 'Bulgaria',];
$countries['CY'] = ['name' => 'Cyprus',];
$countries['CZ'] = ['name' => 'Czech Republic',];
$countries['DE'] = ['name' => 'Germany',];
$countries['DK'] = ['name' => 'Denmark',];
$countries['EE'] = ['name' => 'Estonia',];
$countries['ES'] = ['name' => 'Spain',];
$countries['FI'] = ['name' => 'Finland',];
$countries['FR'] = ['name' => 'France',];
$countries['GB'] = ['name' => 'United Kingdom',];
$countries['GR'] = ['name' => 'Greece',];
$countries['HU'] = ['name' => 'Hungary',];
$countries['HR'] = ['name' => 'Croatia',];
$countries['IE'] = ['name' => 'Ireland, Republic of (EIRE)',];
$countries['IT'] = ['name' => 'Italy',];
$countries['LT'] = ['name' => 'Lithuania',];
$countries['LU'] = ['name' => 'Luxembourg',];
$countries['LV'] = ['name' => 'Latvia',];
$countries['MT'] = ['name' => 'Malta',];
$countries['NL'] = ['name' => 'Netherlands',];
$countries['PL'] = ['name' => 'Poland',];
$countries['PT'] = ['name' => 'Portugal',];
$countries['RO'] = ['name' => 'Romania',];
$countries['SE'] = ['name' => 'Sweden',];
$countries['SI'] = ['name' => 'Slovenia',];
$countries['SK'] = ['name' => 'Slovakia',];
return $countries;
}
?>
@PhilETaylor
Copy link

PhilETaylor commented May 25, 2023 via email

@funder7
Copy link

funder7 commented May 25, 2023

@PhilETaylor can you explain the difference between the two? Thanks

@PhilETaylor
Copy link

Sure - I have to quote this at least once a month as I live in Jersey, Channel Islands, which are also not in the UK, but often people say we are (Ref: https://www.gov.je/Leisure/Jersey/pages/profile.aspx)

GB = "England, Scotland and Wales make up Great Britain"

UK = "The United Kingdom includes Great Britain (England, Scotland and Wales) and Northern Ireland"

@funder7
Copy link

funder7 commented Jun 3, 2023

Very interesting, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment