Plugins - Multiple Select Helper
Add to favoritesMultiple Select Helper
Selecting multiple elements in a list is sometimes tricky. You may click inadvertably on one item of the list and lost all your previous selection. You are forced to use Ctrl (or Command) clicks to select more than one element.
Multiple Select Helper allows you to create easy to use list for multiple selections from array, hashes, collections or trees. The list is build using checkboxes so you can click easily and you will not lost the elements you clicked before. As drawback you lose the use of the keyboard in the "list".
This multiple selections are very useful in many to many relationships (has_and_belongs_to_many or has_many :through with no obligatory fields) where a "add and remove" solution will be cumbersome.
You can find complete documentation and information about how to get the different versions at http://ruido-blanco.net/blog/rails-multiple-select-helper-plugin
Version history
- 20070409
- The old hidden_field toggled by include_hidden_field is now always included (seems like is really needed in Rails 1.2).
- In some situations with the object-method versions of the helpers Rails will fail saying that content_tag expects 3 parameters instead of 2.
- 20070407
- Merge with "Object-method parameters" branch.
- Old versions of the methods are still accesible through "*_tag" versions.
- include_hidden_field removed (not needed in Rails 1.2).
- 20060918
- Changed the hidden_field option to include_hidden_field so it do not clash with Rails hidden_field method.
- Moved all the configuration to a new module not included in ActionView.
- 20060917
- Added hidden_field option.
- Change the default tags to ul and li.
- Added module-wide variables for most used options.
- 20060903
- Added disabled option.
- The ids generated are now HTML 4.01 valid.
- The tree version is more efficient now.
- 20060806
- Initial release.
http://ruido-blanco.net/blog/rails-multiple-select-helper-plugin
http://svn.ruido-blanco.net/multiple_select/trunk/
Rails' (MIT)
View Extensions

It would be nice to have some integration with the form builder, so we can use: form_for do |form| form.collectionmultipleselect(:property) end
Excellent plug in. I can't believe it is not just built in in Rails. Particularly the singularids method on hasmany and hasandbolongs_to_many. I think that it would be a good idea to release a plug in only with that so various other plug ins could just depend on it.