Hey guys, I have a field that will have very few autocomplete options. I have an ajax.autocompleter on it that works great, but I wanted to make it start autocompleting as soon as the field is blur()ed, so that even if the field is empty, the list will still appear. Like a combo box in windows. How can I do this? Setting :min_chars => 0 (or even -1) didn''t work... -Josh ----------- Due to the recent increase in spam and falsely sent email, I now PGP Sign all of my outgoing mail to prove my identity. This means that you will see an attachment called "PGP.sig" with this message. This attachment can be used to prove that I am who I say I am. If you are not familiar with PGP, you can safely ignore it. For more information, please visit http://www.pgp.com/ or http://www.gnupg.org/ -------------- next part -------------- A non-text attachment was scrubbed... Name: PGP.sig Type: application/pgp-signature Size: 194 bytes Desc: This is a digitally signed message part Url : http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/f027b9ec/PGP.bin
Chaz_Meister_Rock
2006-Mar-11 21:20 UTC
[Rails] Re: Ajax.Autocompleter with an empty field
checkout the "frequency" option: http://wiki.script.aculo.us/scriptaculous/show/Ajax.Autocompleter -- Posted via http://www.ruby-forum.com/.
Chaz_Meister_Rock wrote:> checkout the "frequency" option: > > http://wiki.script.aculo.us/scriptaculous/show/Ajax.AutocompleterWell, that didn''t work. But it made me realize that :min_chars isn''t working, either! My code is: <%text_field_with_auto_complete :the_object, :project_name, {} {:with => "''client=''+$F(''the_object_client_id'')+''&''+value", :min_chars => 3, :frequency => 0.1 } %> Yet even with :min_chars => 3, the text filed auto completes with one char... Am I doing this wrong? -- Posted via http://www.ruby-forum.com/.