Please see this:
Let’s get you to set up Country Drop Down Field in Contact Form 7 using Ultimate Addons for Contact Form 7.
1. Turn on the Feature First
If you have installed Contact Form 7 and Ultimate Addons for Contact Form 7 in your system, then from the Dashboard Panel, open Contact>Ultimate Addons. You will find a list of features available for you with a radio button on their right to turn them on.
Find, Country Dropdown Field and turn it on and Save changes from below.
2. Make a Contact Form
The next step is to make a Contact Form. Open Contact>Add New.
Put a title on the Contact Form (i.g. Country Dropdown) and Save changes from the below.
3. Country Dropdown Tag
Now that you’ve created a Contact Form. Open Contact Forms> (Your Contact Form). Inside the admin panel, in the Form section you will find a set of options available for you to generate HTML Tags. You will find a Country Dropdown Tag there.
Open Country Dropdown. You will find below mentioned options inside the Menu that will pop-up:
- Field Type: This section has only one option that asks you whether this Country Dropdown in your Contact Form will be required one or not with a Tick Button on the left of the title.
- Name: This section is auto-generated.
- Auto Complete: This is a pro feature. If you upgrade, the system will track your IP Geolocation and fill in the country name by itself.
- Below the Menu there is an Insert Tag option to insert the HTML Tag for Country Dropdown inside your Contact Form Admin Panel.
4. Setting up Country Dropdown
Now that you have turned on the feature and got a hold of the Country Dropdown Menu, continue following:
- Mark the field required
- Insert Tag
- Rearrange the codes
- Save changes from below
Note: If you want a label for your Country Dropdown Menu, put the blocked code inside <label> Your Country (your Country Dropdown tag) </label>.
5. Mail Setup
To receive the country information of your audiences via email, you need to make a few changes. Open Mail from the key switch panels. Write the mail address where you want to receive your mail inside the To box.
Inside the Mail panel from the key switch panels, you will be suggested a few tags to receive certain information from the Contact Form. To receive the country information, you will find suggested mail tags inside the Admin Panel. Copy the Country Dropdown Tag [uacf7_country_dropdown-220] and place it inside the Message Body as given below:
6. Copy Shortcode
After you are done customizing your Contact Form, Save the changes first. Copy the Shortcode below your Contact Form and Paste the code where you want your Contact Form to be placed.
7. Your Country Dropdown is Ready to Use
After you’ve placed the Shortcode inside the Page, Save and Preview the changes.
Your Contact Form with Country Dropdown Menu is ready to use. Now put the information out there and Submit the form. You will receive a mail like this:
Default country selection feature and specific Country display feature (Pro)
If you want to use default country selection and specific country display feature, you need to install first our UACF7 Addon – IP Geolocation.
After Installing UACF7 Addon – IP Geolocation Pro plugin you will get able to customize these two fields into your country dropdown option field.
- Only Countries -> In this field, you can able to mention your selected country’s ISO code (Alpha-2 code). Per line one country code you can be able to use.
- Default country -> If you want to show a default selected country in your form, you need to mention here that country.
Note: For using the Default selected country feature, You have to uncheck Auto Complete Checkbox.