Posted By


twofivethreetwo on 01/22/09

Tagged


Statistics


Viewed 850 times
Favorited by 2 user(s)

US States Rake Task


/ Published in: Rails
Save to your folder(s)

Populate your states table with US States. Easy rake task for it.


Copy this code and paste it in your HTML
  1. alaska:
  2. id: 1
  3. name: Alaska
  4. abbrev: AK
  5.  
  6. alabama:
  7. id: 2
  8. name: Alabama
  9. abbrev: AL
  10.  
  11. arizona:
  12. id: 3
  13. name: Arizona
  14. abbrev: AZ
  15.  
  16. arkansas:
  17. id: 4
  18. name: Arkansas
  19. abbrev: AR
  20.  
  21. california:
  22. id: 5
  23. name: California
  24. abbrev: CA
  25.  
  26. colorado:
  27. id: 6
  28. name: Colorado
  29. abbrev: CO
  30.  
  31. connecticut:
  32. id: 7
  33. name: Connecticut
  34. abbrev: CT
  35.  
  36. delaware:
  37. id: 8
  38. name: Delaware
  39. abbrev: DE
  40.  
  41. dc:
  42. id: 9
  43. name: District of Columbia
  44. abbrev: DC
  45.  
  46. florida:
  47. id: 10
  48. name: Florida
  49. abbrev: FL
  50.  
  51. georgia:
  52. id: 11
  53. name: Georgia
  54. abbrev: GA
  55.  
  56. hawaii:
  57. id: 12
  58. name: Hawaii
  59. abbrev: HI
  60.  
  61. idaho:
  62. id: 13
  63. name: Idaho
  64. abbrev: ID
  65.  
  66. illinois:
  67. id: 14
  68. name: Illinois
  69. abbrev: IL
  70.  
  71. indiana:
  72. id: 15
  73. name: Indiana
  74. abbrev: IN
  75.  
  76. iowa:
  77. id: 16
  78. name: Iowa
  79. abbrev: IA
  80.  
  81. kansas:
  82. id: 17
  83. name: Kansas
  84. abbrev: KS
  85.  
  86. kentucky:
  87. id: 18
  88. name: Kentucky
  89. abbrev: KY
  90.  
  91. kouisiana:
  92. id: 19
  93. name: Louisiana
  94. abbrev: LA
  95.  
  96. maine:
  97. id: 20
  98. name: Maine
  99. abbrev: ME
  100.  
  101. maryland:
  102. id: 21
  103. name: Maryland
  104. abbrev: MD
  105.  
  106. massachusetts:
  107. id: 22
  108. name: Massachusetts
  109. abbrev: MA
  110.  
  111. michigan:
  112. id: 23
  113. name: Michigan
  114. abbrev: MI
  115.  
  116. minnesota:
  117. id: 24
  118. name: Minnesota
  119. abbrev: MN
  120.  
  121. mississippi:
  122. id: 25
  123. name: Mississippi
  124. abbrev: MS
  125.  
  126. missouri:
  127. id: 26
  128. name: Missouri
  129. abbrev: MO
  130.  
  131. montana:
  132. id: 27
  133. name: Montana
  134. abbrev: MT
  135.  
  136. nebraska:
  137. id: 28
  138. name: Nebraska
  139. abbrev: NE
  140.  
  141. nevada:
  142. id: 29
  143. name: Nevada
  144. abbrev: NV
  145.  
  146. newhampshire:
  147. id: 30
  148. name: New Hampshire
  149. abbrev: NH
  150.  
  151. newjersey:
  152. id: 31
  153. name: New Jersey
  154. abbrev: NJ
  155.  
  156. newmexico:
  157. id: 32
  158. name: New Mexico
  159. abbrev: NM
  160.  
  161. newyork:
  162. id: 33
  163. name: New York
  164. abbrev: NY
  165.  
  166. northcarolina:
  167. id: 34
  168. name: North Carolina
  169. abbrev: NC
  170.  
  171. northdakota:
  172. id: 35
  173. name: North Dakota
  174. abbrev: ND
  175.  
  176. ohio:
  177. id: 36
  178. name: Ohio
  179. abbrev: OH
  180.  
  181. oklahoma:
  182. id: 37
  183. name: Oklahoma
  184. abbrev: OK
  185.  
  186. oregon:
  187. id: 38
  188. name: Oregon
  189. abbrev: OR
  190.  
  191. pennsylvania:
  192. id: 39
  193. name: Pennsylvania
  194. abbrev: PA
  195.  
  196. rhodeisland:
  197. id: 40
  198. name: Rhode Island
  199. abbrev: RI
  200.  
  201. southcarolina:
  202. id: 41
  203. name: South Carolina
  204. abbrev: SC
  205.  
  206. southdakota:
  207. id: 42
  208. name: South Dakota
  209. abbrev: SD
  210.  
  211. tennessee:
  212. id: 43
  213. name: Tennessee
  214. abbrev: TN
  215.  
  216. texas:
  217. id: 44
  218. name: Texas
  219. abbrev: TX
  220.  
  221. utah:
  222. id: 45
  223. name: Utah
  224. abbrev: UT
  225.  
  226. vermont:
  227. id: 46
  228. name: Vermont
  229. abbrev: VT
  230.  
  231. virginia:
  232. id: 47
  233. name: Virginia
  234. abbrev: VA
  235.  
  236. washington:
  237. id: 48
  238. name: Washington
  239. abbrev: WA
  240.  
  241. westvirginia:
  242. id: 49
  243. name: West Virginia
  244. abbrev: WV
  245.  
  246. wisconsin:
  247. id: 50
  248. name: Wisconsin
  249. abbrev: WI
  250.  
  251. wyoming:
  252. id: 51
  253. name: Wyoming
  254. abbrev: WY

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.