Webform Country List
Categories
Component ID
Component name
Component type
Maintenance status
Development status
Component security advisory coverage
Downloads
Component created
Component changed
Component body
A webform component that lets the user select a country out of a list that you can configure. It is compatible with both, webform version 3 and version 4.
If the PHP PECL package geoip is available and it detects the country of the visitor, and this country is in the list of available countries, webform_country_list preselects the geoip country as default.
Configuration
When adding a new component to your webform choose 'Country List' as type.
When editing the component check the 'available' checkbox for all countries that you want to include in the select box.
By draging and dropping the "cross" sign you can also change the order in which the countries appear in the select box.
If no country is selected when editing the component, all countries will be available in the webform.
Installation
Nothing special, if you're using drush that would be
drush dl webform_country_listdrush en webform_country_list -y
You can find more information about installing contributed modules here:
Installing modules (Drupal 7)
Instructions for installing geoip can be found here.
Dependencies
Hard dependencies:
- webform (version 3 or 4)
Soft dependencies:
- PHP PECL package geoip
Indirect dependencies from webform 4:
Related modules
- countries ... a country field which has no webform support
- Piped lists of countries... a country list for copy & paste. You have to create the webform component yourself.
