[jQuery] Re: findValue

2009-03-20 Thread Bright Dadson
Thanks very much guys for the advice - it is really usefull to me. Apppreciate it alot. Quick question! my code has been altered to reflect the change suggested, like this; $("#operator").autocomplete("auto.php", { delay:10, lineSeparator: "^", cacheLength: 10, mat

[jQuery] Re: findValue

2009-03-19 Thread Eric Garside
Also, pretty sure you just did it for development purposes, but you probably shouldn't use an alert in an autocomplete context. :P On Mar 19, 3:32 pm, ricardobeat wrote: > I guess the problem is this line: > > var ac = $("#operator")[0].autocompleter.findValue(); > > $(..)[0] gives you the first

[jQuery] Re: findValue

2009-03-19 Thread ricardobeat
I guess the problem is this line: var ac = $("#operator")[0].autocompleter.findValue(); $(..)[0] gives you the first HTML Element in the object. It's not a jQuery object anymore, so the autocompleter property doesn't exist. IDs should be unique so that is unneeded, try changing it to var ac =

[jQuery] Re: findValue

2009-03-19 Thread brightdad...@googlemail.com
Thanks for the suggestion Lauri. I have tried as asuggested and still dont see anything happening.

[jQuery] Re: findValue

2009-03-19 Thread Lauri B.
Didn't try it, but maybe you should use if($Suggest == ''){ alert("we donot have any matching result"); }

[jQuery] Re: findValue

2009-03-19 Thread brightdad...@googlemail.com
I have tried this too and doesn't seem to work: $("#operator").autocomplete("auto.php", { delay:10, lineSeparator: "^", cacheLength: 10, matchSubset:1, matchContains:1, onFindValue:function(){ alert("am here"); var a