I've just installed the Search Autocomplete module on my Drupal 7 site and try to get it to work. For this I also installed the jQuery update module and put it on jQuery 1.10. I didn't change any of the default settings of the search autocomplete module. When I start typing in my search field I get this jquery error:
Uncaught TypeError: Cannot read property 'label' of null jquery.ui.autocomplete.min.js?v=1.10.2:4 Uncaught TypeError: Cannot read property 'label' of null
So I tried finding out what is wrong by setting a breakpoint in the autocomplete jquery file. What I found out is that that on line 474 of this file there is this check:
if ( items.length && items[0].label && items[0].value ) { return items; }
But it says that items is [null]. So I went back to views. The automatic generated view made by the autocomplete module outputs this:
[
{
"link" : "http://site.local:8888/content/elke",
"value" : "Elke",
"fields" : {
"view_node" : "<a href=\"/content/elke\">view</a>",
"title" : "Elke"
},
"group" : {
"group_id" : "",
"group_name" : ""
}
},
{
"link" : "http://site.local:8888/content/peuterdans",
"value" : "Peuterdans",
"fields" : {
"view_node" : "<a href=\"/content/peuterdans\">view</a>",
"title" : "Peuterdans"
}
},
{
"link" : "http://site.local:8888/content/sofie",
"value" : "Sofie",
"fields" : {
"view_node" : "<a href=\"/content/sofie-noij\">view</a>",
"title" : "Sofie"
}
}
]
So it's not null but is it the right output (following this http://api.jqueryui.com/autocomplete/ it is) for the jquery autocomplete? What am I doing wrong here?