Lib file state_select.rb

Published on Author Akhil Bansal7 Comments

If you are not interested in installing a plugin just for one method(state_select) then You can put state_select.rb file in you rails lib directory. And include state_select.rb file in your controller where ever you want to use state_select method.

The url for state_select.rb is http://github.com/bansalakhil/stateselect/tree/master/lib/state_select.rb
Feedback please….

7 Responses to Lib file state_select.rb

  1. Should upcase the country name when appending _STATE to it.

    Also need some adjustments to the Canadian provinces:

    [“Alberta”, “British Columbia”, “Manitoba”, “New Brunswick”, “Newfoundland”, “Northwest Territories”, “Nova Scotia”, “Nunavut”, “Ontario”, “Prince Edward Island”, “Quebec”, “Saskatchewan”, “Yukon”],

    Otherwise, looks nice!

  2. Thanks for the state_select plugin!

    However, when I run script/plugin it installs your plug to /vendor/plugins/trunk

    Other plugins I want to install (file_column) write to the same directory /vendor/plugins/trunk, overwriting your files.

    Is this correct behavior? Shouldn’t the plugin install to something like /vendor/plugins/state_select ?

    I’m a rails newb so I might be missing something here.

    Thanks again for your hard work.

    Daniel
    Oakland, CA

Leave a Reply

Your email address will not be published. Required fields are marked *