Status/Resolution/Reason: Closed/Fixed/
Reporter/Name(from Bugbase): marc esher / marc esher (marcesher)
Created: 01/28/2009
Components: AJAX, UI Components
Versions: 9.0
Failure Type: Unspecified
Found In Build/Fixed In Build: 0000 / 227591
Priority/Frequency: Major / Most users will encounter
Locale/System: English / Platforms All
Vote Count: 0
Problem:
autosuggest is too aggressive
Let me explain:
Given this code:
<cfform name="blah">
<cfinput autosuggest="cfc:autosuggesttarget.getList({cfautosuggestvalue})" name="blah2" autosuggestbinddelay="1">
</cfform>
if you then go to your form and just hit random keys really fast, the autosuggest will fire off dozens of remote calls to the server.
This bug has existed since cf8 launched. I showed Ben during his ajax presentation at MAX in 2007, and he seemed surprised by this behavior as well.
I can tell you that where i work, we ditched the built-in autosuggest and replaced it with Spry, which does not exhibit this behavior. In spry, if you type like mad, it'll only fire off a single request to the server, after the typing is finished.
Method:
create a cfm page with this code:
<cfform name="blah">
<cfinput autosuggest="cfc:autosuggesttarget.getList({cfautosuggestvalue})" name="blah2" autosuggestbinddelay="1">
</cfform>
load the page, and type as fast as you can in the form field.
For my case, I open up firebug, go to the "Net" tab, and watch it dispatch dozens of calls to the server.
Result:
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 3037391
External Customer Info:
External Company:
External Customer Name: marc esher
External Customer Email: 70390EBF47F01CAF992015B9
External Test Config: 01/28/2009
Attachments:
Comments: