javascript - Why am I unable to push these results to an array? -
i'm trying change
results = $("x", xmlresponse).map(function() {
to
results.push = $("x", xmlresponse).map(function() {
but doing prevents autocomplete suggestions appearing.
if remove "push" again, autocomplete suggestions appear correctly no issue.
how can use results.push here?
use .get() return array .map()
results = $("game", xmlresponse).map(function() { return { value: $("gametitle", this).text() + ", " + ($.trim($("releasedate", this).text()) || "(unknown date)") }; }).get()
Comments
Post a Comment