Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic datasource #18

Open
Guris opened this issue May 25, 2012 · 1 comment
Open

Dynamic datasource #18

Guris opened this issue May 25, 2012 · 1 comment

Comments

@Guris
Copy link

Guris commented May 25, 2012

Hi. I'm unable to chenge data that AutoComplete uses to render suggestions. It can be assigned only when binding AutoComplete to input element.
I am able to retrieve data from my webservice but I don't know how to pass them to autocomplete a call some kind of rebind.

Is this possible, please? Help would be very appreciated!
Thank you.

@jsbase
Copy link

jsbase commented Aug 23, 2012

Hi,

actually I have the same problem:
once autosuggest was bind on its input field I can't change the datascoure no more.

for example like this:
var data = [{name: "foo"}, {name: "bar"}];
$('input').autoSuggest(data);

even if i run the same line again with another datascource it takes the old datasource

// init
var data = [{name: "foo"}, {name: "bar"}];
$('input').autoSuggest(data);

// update datasource
var newData = [{name: "what"}, {name: "the"}, {name: "f..."}];
$("input").autoSuggest(newData);

nobody has any idea why?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants