Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
29 lines (14 sloc) 583 Bytes


A country-select compatible country selector helper which uses ISO country codes.


Add this line to your application's Gemfile:

gem 'country-code-select'

And then execute:

$ bundle

Or install it yourself as:

$ gem install country-code-select


Simple use supplying model and attribute as parameters:

country_select("user", "country_name")

Supplying priority countries to be placed at the top of the list. Countries entered should be the country code.:

country_select("user", "country_name", [ "GB", "FR", "US" ])