<?php
$country_codes = array('UK','IRL');
$country_list = array(
'ALB' => 'Albania',
'AND' => 'Andorra',
'ARM' => 'Armenia',
'AUT' => 'Austria',
'AZE' => 'Azerbaijan',
'BLR' => 'Belarus',
'BEL' => 'Belgium',
'BIH' => 'Bosnia and Herzegovina',
'BGR' => 'Bulgaria',
'HRV' => 'Croatia',
'CYP' => 'Cyprus',
'CZE' => 'Czech Republic',
'DNK' => 'Denmark',
'EST' => 'Estonia',
'FIN' => 'Finland',
'FRA' => 'France',
'GEO' => 'Georgia',
'DEU' => 'Germany',
'GRC' => 'Greece',
'HUN' => 'Hungary',
'ISL' => 'Iceland',
'IRL' => 'Ireland',
'ITA' => 'Italy',
'KAZ' => 'Kazakhstan',
'RKS' => 'Kosovo',
'LVA' => 'Latvia',
'LIE' => 'Liechtenstein',
'LTU' => 'Lithuania',
'LUX' => 'Luxembourg',
'MLT' => 'Malta',
'MDA' => 'Moldova',
'MCO' => 'Monaco',
'MNE' => 'Montenegro',
'NLD' => 'Netherlands',
'MKD' => 'North Macedonia',
'NOR' => 'Norway',
'POL' => 'Poland',
'PRT' => 'Portugal',
'ROU' => 'Romania',
'RUS' => 'Russia',
'SMR' => 'San Marino',
'SRB' => 'Serbia',
'SVK' => 'Slovakia',
'SVN' => 'Slovenia',
'ESP' => 'Spain',
'SWE' => 'Sweden',
'CHE' => 'Switzerland',
'TUR' => 'Turkey',
'UKR' => 'Ukraine',
'UK' => 'UK',
);
$filtered_countries = array_intersect_key($country_list, array_flip($country_codes));
print_r($filtered_countries);
preferences:
33.68 ms | 402 KiB | 5 Q