Advanced Custom Fields: ACF Country
ACF Country field - Display a select field of all countries, in any language.
by Nicolas Lemoine · github.com/nlemoine/acf-country · website
★ 121stars
99kcomposer installs
17forks
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/nlemoine/acf-country/archive/refs/heads/3.x.zipAlso on Packagist as hellonico/acf-country:
composer require hellonico/acf-countryDeclares an update source (https://github.com/nlemoine/acf-country.), so updates arrive through the plugin's own updater.
From the readme
ACF Country field
Adds a 'Country' field type for the Advanced Custom Fields WordPress plugin.
⚠️ WARNING ⚠️
From version 2.0.0, ACF Country introduced some important breaking changes:
- Dropped support for older PHP & ACF versions, new requirements are:
- ACF 5.7+
- PHP 5.4+
- Return format has changed. To better stick to ACF and make use of ACF functions, ACF Country will now return values the same way select field do. ['FR' = 'France'] will now look like ['label' = 'France', 'value' = 'FR']
Looking for a ACF pre 5.7 support? Check the 1.0 branch.
Overview
Display a select list of all countries in your language.
Country names are available in every language (see available list). By default, country names are localized in your current WordPress language.
Select a single value:
Or multiple ones:
Compatibility
- ACF 5.7+
- PHP 5.4+
Field options
| Option | Default | Description |
| ------------- | ------------- | ------------- |
| Default value | emtpy | Set a default value for the country field (as country code) |
| Allow null | false | Enable/disable null value |
| Allow multiple | false | Enable/disable multiple countries selection |
| Stylised UI | true |
Read the full README on GitHub →
Releases
| Tag | Published | Asset | Downloads |
|---|---|---|---|
| v3.0.1 | Mar 15, 2024 | — | — |
| v3.0.0 | Feb 23, 2024 | — | — |
| 2.1.0 | Nov 4, 2023 | — | — |
| 2.0.2 | Sep 17, 2020 | — | — |
| 2.0.1 | Feb 10, 2020 | — | — |
| 2.0.0 | Dec 3, 2018 | — | — |
| 1.3.0 | Nov 30, 2018 | — | — |
| 1.4.0 | Nov 30, 2018 | — | — |
| 1.2.0 | Nov 30, 2018 | — | — |
| 1.2.1 | May 4, 2017 | — | — |
| 1.1.2 | Mar 31, 2017 | — | — |
| 1.1.1 | Feb 3, 2017 | — | — |
| 1.0.0 | Jan 10, 2017 | — | — |
| 1.1.0 | Jan 10, 2017 | — | — |