Plugins - model_auto_completer
Add to favoritesmodel_auto_completer provides autocompletion for models. That is, the user autocompletes a text field, but the widget is able to manage a hidden field that stores the ID of the model that corresponds to the selected completion.
Such a widget may be useful when the number of options is too much for a select. Say you need to assign a director to a movie having a database of hundreds of directors. With this plugin it is easy to let the user autocomplete by director name, and have a robust database ID managed under the hood.
http://model-ac.rubyforge.org/
svn://rubyforge.org/var/svn/model-ac/trunk/vendor/plugins/model_auto_completer
Rails' (MIT)
View Extensions


Well done,Xavier,thanks a lot.
@Javier Vidal, thank you, added to the docs of 1.5.
@Wolfram, provided as a flag :appendrandomsuffix, in 1.5 as well.
If you want modelautocompleter not to generate inline CSS, just:
<%= belongsto_autocompleter :book, :author, :fullname, {}, {}, { :skip_style => true } %>
@Wolfram: good, I'm working on a new release and will add this feature. Thank you!
This is a cool plugin. I'm missing a way to turn off the automatic suffix generation for the text field ID. This screws up the automatic insertion of a div tag for error highlighting if the field is wrong/missing (relevant only here, if :allowfreetext => true), of course.