forked from jslag/us-state-select-plugin
-
Notifications
You must be signed in to change notification settings - Fork 4
/
README
32 lines (23 loc) · 769 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
UsStates
========
From http://svn.techno-weenie.net/projects/plugins/us_states/, updated
to run under rails 2.2.
To select "priority" states that show up at the top of the list, call
like so:
<%= us_state_select 'child', 'state', :priority => %w(TX CA) %>
To select the way states display option and value:
this (default):
<%= us_state_select 'child', 'state'%>
will yield this:
<option value="AK">Alaska</option>
______
this:
<%= us_state_select 'child', 'state', :show => :full %>
will yield this:
<option value="Alaska">Alaska</option>
______
Options are:
:full = <option value="Alaska">Alaska</option>
:full_abb = <option value="AK">Alaska</option>
:abbreviations = <option value="AK">AK</option>
::abb_full_abb = <option value="AK">AK - Alaska</option>