Thanks for the ticket!

Jörn

On Wed, Mar 25, 2009 at 11:32 PM, Diego Plentz <diego.pi...@gmail.com> wrote:
> I suspected :-)
>
> Well, I archived the results that I want doing a modification to the
> autocomplete source code. I've added a "async" option, so if someone want's
> to use asyncs requests as a source of data it can now be done. The result is
> pretty simple:
>
> $("#city").autocomplete({
>    async: dwrHandler
> });
>
> function dwrHandler(term, handler){
>  CityAutoComplete.find(term, handler);
> }
>
> Hope that It can be added to the source :-)
>
> I created a ticket for this http://dev.jqueryui.com/ticket/4402
>
> Thanks again
>
>
> On Wed, Mar 25, 2009 at 11:12 AM, Jörn Zaefferer
> <joern.zaeffe...@googlemail.com> wrote:
>>
>> Ah, sorry. "source" expects a synchronous return as well, doesn't help
>> at all in this case.
>>
>> Jörn
>>
>> On Wed, Mar 25, 2009 at 2:24 PM, Diego Plentz <diego.pi...@gmail.com>
>> wrote:
>> > Thanks Jörn. Btw, the problem still here, because even if I do something
>> > like that:
>> >
>> > $("#city").autocomplete({
>> >     source: handleDWR
>> > });
>> >
>> > function handleDWR(term){
>> >   TestAutoComplete.findAutoComplete(term, function(data) {return data});
>> > }
>> >
>> > "data" never goes back to autocomplete to be properly rendered (because
>> > it
>> > is a asynchronous call). What am I missing here?
>> >
>> > Thanks again!
>> >
>> > On Tue, Mar 24, 2009 at 7:36 PM, Jörn Zaefferer
>> > <joern.zaeffe...@googlemail.com> wrote:
>> >>
>> >> The jQuery UI branch of the autocomplete plugin supports a
>> >> source-option as an alternative to the url- und data-options. Give it
>> >> a try and let us know if it works for you:
>> >> http://jquery-ui.googlecode.com/svn/branches/dev/autocomplete/
>> >> http://jqueryui.pbwiki.com/SelectComboboxAutocomplete
>> >>
>> >> Jörn
>> >>
>> >> On Tue, Mar 24, 2009 at 10:39 PM, Diego Plentz <diego.pi...@gmail.com>
>> >> wrote:
>> >> > Hey guys,
>> >> >
>> >> > I'm using jquery + autocomplete plugin (by Jörn) and I trying to make
>> >> > it
>> >> > work with DWR(http://directwebremoting.org/). My problem is that
>> >> > jquery
>> >> > autocomplete takes a url or data directly, but to make DWR works
>> >> > properly, I
>> >> > must use their javascript functions and handle the callback. Here is
>> >> > a
>> >> > example:
>> >> >
>> >> > TestAutoComplete.findAutoComplete(token, function(data) { /* do
>> >> > something
>> >> > with data*/ });
>> >> >
>> >> > How to make it work with autocomplete, that works like this:
>> >> >
>> >> > $("#city").autocomplete(cities);
>> >> >
>> >> > Thanks in advance
>> >> >
>> >> > --
>> >> > http://plentz.org
>> >> >
>> >
>> >
>> >
>> > --
>> > http://plentz.org
>> >
>
>
>
> --
> http://plentz.org
>

Reply via email to