plapinte-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org
2007-Jul-23 11:29 UTC
Avoid database query when onblur event fired
Hello, In some cases, I would like to avoid database query when onblur event is fired, I already have this event in my code, ie : <INPUT type="text" id="city1" name="city1" onblur="search_city_onblur(this);"> So I don''t want that autocompleter do it again, how to do that ? Thank you very much, plapinte --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
HI, I do not know If I got you right ... but to avoid the autocompletion add >autocomplete="off"< to the input tag. hf Bastian On 7/23/07, plapinte-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org <plapinte-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> > > Hello, > > In some cases, I would like to avoid database query when onblur event > is fired, > > I already have this event in my code, ie : > <INPUT type="text" id="city1" name="city1" > onblur="search_city_onblur(this);"> > > So I don''t want that autocompleter do it again, how to do that ? > > Thank you very much, > plapinte > > > > >-- -- spread the word ... see www.browsehappy.com ;o) Calvin: Weekends don''t count unless you spend them doing something completely pointless. Join the Greater IBM Connection ( http://www.xing.com/premiumgroup-6291.d26b7d) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
plapinte-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org
2007-Jul-23 12:22 UTC
Re: Avoid database query when onblur event fired
Hi, In fact, I dont''t want autocomplete when text is written quickly .. But in this case, I saw in database logfile that autocomplete query is executed when navigating in next field (by TAB), So job is done twice (2 queries, one from my onblur and one from autocomplete) and mine is faster because it use = operator, not LIKE, Any idea ? Thanks, Plapinte On 23 juil, 14:01, "Bastian Feder" <bastian.fe...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> HI, > I do not know If I got you right ... > but to avoid the autocompletion add >autocomplete="off"< to the input tag. > > hf > Bastian > > On 7/23/07, plapi...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org <plapi...-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote: > > > > > > > Hello, > > > In some cases, I would like to avoid database query when onblur event > > is fired, > > > I already have this event in my code, ie : > > <INPUT type="text" id="city1" name="city1" > > onblur="search_city_onblur(this);"> > > > So I don''t want that autocompleter do it again, how to do that ? > > > Thank you very much, > > plapinte > > -- > -- > spread the word ... seewww.browsehappy.com;o) > > Calvin: Weekends don''t count unless you spend them doing something > completely pointless. > > Join the Greater IBM Connection (http://www.xing.com/premiumgroup-6291.d26b7d)--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---