Overview
A 'CountryList' form field is available to add to your form, removing the need to create this field from scratch. Once added, this field will allow users to select a country from the form dropdown list.
An overview of how to setup forms can be found here.
Setup
Adding the CountryList field
Add a new field type, selecting 'Country List' as the field type.
This will create a 'Country' dropdown on your form.
Changing the Captured Value
Once a user has selected a country from the dropdown and completed the form, the value captured will be country code, rather than the full country name. This is because the the default setting for this field type is set to capture country code, the below screenshot shows the field settings where the value column shows the content that will be captured with each lead.
To change the capture value to instead capture the full country name, download the attached JSON file found at the bottom of this article. This JSON will allow you to swap the country code capture to full country name capture with each lead.
Once the file is downloaded, open the field settings.
Copy and paste the values of the JSON file into the 'Import JSON' field and then click 'Import'.
Once imported, the new values will be added to the existing list of dropdown field options. Any existing values will not be replaced, so these options may need to be removed manually.
Setting the Default Dropdown Value
Click the CountryList field 'Settings'
Navigate to the 'Options' tab, and input the value that should be the default option when the form loads. In the example below, the country code of 'US' was input into the 'Default Value' field, which then loads the 'US' option in the form dropdown as default. if the values of the field are changed to instead capture full country names (as per the above instructions) then the 'Default Value' should match the value of your field options, e.g. 'United States' instead of 'US.