Quantcast

Autocomplete - suggestions not loading

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Autocomplete - suggestions not loading

Leila Gonzales

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Autocomplete - suggestions not loading

Demian Katz

Leila,


I see that autocomplete is working on the public 3.1.3 demo at https://vufind.org/demo, so I don't think the feature itself is universally broken (unless there is something browser-specific going on). Thus, it may be helpful to narrow down what about your installation is influencing the problem. If you change to the default theme, does the behavior change? Do you see the problem for all types of searches, or just some? Does changing the relevant searches.ini settings here make any difference?


https://github.com/vufind-org/vufind/blob/master/config/vufind/searches.ini#L503


If you watch the AJAX calls in the network tab of your browser's debugging tool, is there a response coming back? In other words, is the problem that the AJAX call is returning a blank list, or is it that it's returning a valid response and the JS is dropping it for some reason?


I hope one of those ideas helps, but if not, please check back in and let us know what you have found so far!


thanks,

Demian




From: Leila Gonzales <[hidden email]>
Sent: Wednesday, May 10, 2017 8:57 PM
To: [hidden email]
Subject: [VuFind-Tech] Autocomplete - suggestions not loading
 

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Autocomplete - suggestions not loading

Leila Gonzales

Thanks for the troubleshooting tips Demian.


I agree this feature isn’t universally broken, as I have it working on another 3.1.3 installation, and as you mention, the demo site works just fine.

 

I’ve tested this on Firefox and Chrome, and the issue persists on both, and if I change the default theme and modules to the base install (bootstrap3 and VuFind), the issue persists. Also, the problem exists for all types of searches and changing the relevant searches.ini settings doesn’t fix the issue.

 

I copied over fresh copies of autocomplete.js and common.js from #8a4d2ba but the issue is still happening.

 

When I watch the AJAX calls in the network, the response is coming back fine, so that leads me to suspect the issue is with the JS.  The code is making it through most of the $.fn.autocomplete.ajax loop in common.js (L#219), but the success function (L#229) in that loop is never called.  In autocomplete.js, the code makes it to #L105, but never to #L106 , and so eventho’ the AJAX response is coming back, the autocomplete-results hidden item list is never updated, I think because the createList() function is never called.  


Do you think it would be best to do a full re-install of VuFind 3.1.3, or is there another place I should be looking to figure out why the code’s not working the way it’s supposed to?

 

Thanks,
Leila

 

From: Demian Katz [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 4:53 AM
To: Leila Gonzales; [hidden email]
Subject: Re: [VuFind-Tech] Autocomplete - suggestions not loading

 

Leila,

 

I see that autocomplete is working on the public 3.1.3 demo at https://vufind.org/demo, so I don't think the feature itself is universally broken (unless there is something browser-specific going on). Thus, it may be helpful to narrow down what about your installation is influencing the problem. If you change to the default theme, does the behavior change? Do you see the problem for all types of searches, or just some? Does changing the relevant searches.ini settings here make any difference?

 

https://github.com/vufind-org/vufind/blob/master/config/vufind/searches.ini#L503

 

If you watch the AJAX calls in the network tab of your browser's debugging tool, is there a response coming back? In other words, is the problem that the AJAX call is returning a blank list, or is it that it's returning a valid response and the JS is dropping it for some reason?

 

I hope one of those ideas helps, but if not, please check back in and let us know what you have found so far!

 

thanks,

Demian

 


From: Leila Gonzales <[hidden email]>
Sent: Wednesday, May 10, 2017 8:57 PM
To: [hidden email]
Subject: [VuFind-Tech] Autocomplete - suggestions not loading

 

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Autocomplete - suggestions not loading

Demian Katz
Is it possible there is something weird going on with the HTTP status code?

I will try to remember to ask Chris for ideas too....

- Demian


From: Leila Gonzales <[hidden email]>
Sent: Thursday, May 11, 2017 11:37:36 AM
To: Demian Katz; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading
 

Thanks for the troubleshooting tips Demian.


I agree this feature isn’t universally broken, as I have it working on another 3.1.3 installation, and as you mention, the demo site works just fine.

 

I’ve tested this on Firefox and Chrome, and the issue persists on both, and if I change the default theme and modules to the base install (bootstrap3 and VuFind), the issue persists. Also, the problem exists for all types of searches and changing the relevant searches.ini settings doesn’t fix the issue.

 

I copied over fresh copies of autocomplete.js and common.js from #8a4d2ba but the issue is still happening.

 

When I watch the AJAX calls in the network, the response is coming back fine, so that leads me to suspect the issue is with the JS.  The code is making it through most of the $.fn.autocomplete.ajax loop in common.js (L#219), but the success function (L#229) in that loop is never called.  In autocomplete.js, the code makes it to #L105, but never to #L106 , and so eventho’ the AJAX response is coming back, the autocomplete-results hidden item list is never updated, I think because the createList() function is never called.  


Do you think it would be best to do a full re-install of VuFind 3.1.3, or is there another place I should be looking to figure out why the code’s not working the way it’s supposed to?

 

Thanks,
Leila

 

From: Demian Katz [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 4:53 AM
To: Leila Gonzales; [hidden email]
Subject: Re: [VuFind-Tech] Autocomplete - suggestions not loading

 

Leila,

 

I see that autocomplete is working on the public 3.1.3 demo at https://vufind.org/demo, so I don't think the feature itself is universally broken (unless there is something browser-specific going on). Thus, it may be helpful to narrow down what about your installation is influencing the problem. If you change to the default theme, does the behavior change? Do you see the problem for all types of searches, or just some? Does changing the relevant searches.ini settings here make any difference?

 

https://github.com/vufind-org/vufind/blob/master/config/vufind/searches.ini#L503

 

If you watch the AJAX calls in the network tab of your browser's debugging tool, is there a response coming back? In other words, is the problem that the AJAX call is returning a blank list, or is it that it's returning a valid response and the JS is dropping it for some reason?

 

I hope one of those ideas helps, but if not, please check back in and let us know what you have found so far!

 

thanks,

Demian

 


From: Leila Gonzales <[hidden email]>
Sent: Wednesday, May 10, 2017 8:57 PM
To: [hidden email]
Subject: [VuFind-Tech] Autocomplete - suggestions not loading

 

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Autocomplete - suggestions not loading

Leila Gonzales

The HTTP status code returns 200 OK. I also tried clearing the cache, restarting apache and also restarting VuFind. No luck. Thanks for asking Chris for ideas too. I’ll keep poking around to see if I can figure this out. Thanks again for the help!

- Leila

 

From: Demian Katz [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 11:02 AM
To: Leila Gonzales; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

Is it possible there is something weird going on with the HTTP status code?

I will try to remember to ask Chris for ideas too....

- Demian


From: Leila Gonzales <[hidden email]>
Sent: Thursday, May 11, 2017 11:37:36 AM
To: Demian Katz; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

Thanks for the troubleshooting tips Demian.


I agree this feature isn’t universally broken, as I have it working on another 3.1.3 installation, and as you mention, the demo site works just fine.

 

I’ve tested this on Firefox and Chrome, and the issue persists on both, and if I change the default theme and modules to the base install (bootstrap3 and VuFind), the issue persists. Also, the problem exists for all types of searches and changing the relevant searches.ini settings doesn’t fix the issue.

 

I copied over fresh copies of autocomplete.js and common.js from #8a4d2ba but the issue is still happening.

 

When I watch the AJAX calls in the network, the response is coming back fine, so that leads me to suspect the issue is with the JS.  The code is making it through most of the $.fn.autocomplete.ajax loop in common.js (L#219), but the success function (L#229) in that loop is never called.  In autocomplete.js, the code makes it to #L105, but never to #L106 , and so eventho’ the AJAX response is coming back, the autocomplete-results hidden item list is never updated, I think because the createList() function is never called.  


Do you think it would be best to do a full re-install of VuFind 3.1.3, or is there another place I should be looking to figure out why the code’s not working the way it’s supposed to?

 

Thanks,
Leila

 

From: Demian Katz [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 4:53 AM
To: Leila Gonzales; [hidden email]
Subject: Re: [VuFind-Tech] Autocomplete - suggestions not loading

 

Leila,

 

I see that autocomplete is working on the public 3.1.3 demo at https://vufind.org/demo, so I don't think the feature itself is universally broken (unless there is something browser-specific going on). Thus, it may be helpful to narrow down what about your installation is influencing the problem. If you change to the default theme, does the behavior change? Do you see the problem for all types of searches, or just some? Does changing the relevant searches.ini settings here make any difference?

 

https://github.com/vufind-org/vufind/blob/master/config/vufind/searches.ini#L503

 

If you watch the AJAX calls in the network tab of your browser's debugging tool, is there a response coming back? In other words, is the problem that the AJAX call is returning a blank list, or is it that it's returning a valid response and the JS is dropping it for some reason?

 

I hope one of those ideas helps, but if not, please check back in and let us know what you have found so far!

 

thanks,

Demian

 


From: Leila Gonzales <[hidden email]>
Sent: Wednesday, May 10, 2017 8:57 PM
To: [hidden email]
Subject: [VuFind-Tech] Autocomplete - suggestions not loading

 

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Autocomplete - suggestions not loading

Leila Gonzales
In reply to this post by Demian Katz

I did a fresh install of VuFind 3.1.3 and the issue persists, so I’m going to look into the server configuration to see if there’s something there that’s causing the problem. Since the information is being returned in the AJAX call, and I can see it in the browser, there must be something stopping the handoff to the JS file.

 

-Leila

 

From: Leila Gonzales [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 11:52 AM
To: 'Demian Katz'; '[hidden email]'
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

The HTTP status code returns 200 OK. I also tried clearing the cache, restarting apache and also restarting VuFind. No luck. Thanks for asking Chris for ideas too. I’ll keep poking around to see if I can figure this out. Thanks again for the help!

- Leila

 

From: Demian Katz [[hidden email]]
Sent: Thursday, May 11, 2017 11:02 AM
To: Leila Gonzales; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

Is it possible there is something weird going on with the HTTP status code?

I will try to remember to ask Chris for ideas too....

- Demian


From: Leila Gonzales <[hidden email]>
Sent: Thursday, May 11, 2017 11:37:36 AM
To: Demian Katz; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

Thanks for the troubleshooting tips Demian.


I agree this feature isn’t universally broken, as I have it working on another 3.1.3 installation, and as you mention, the demo site works just fine.

 

I’ve tested this on Firefox and Chrome, and the issue persists on both, and if I change the default theme and modules to the base install (bootstrap3 and VuFind), the issue persists. Also, the problem exists for all types of searches and changing the relevant searches.ini settings doesn’t fix the issue.

 

I copied over fresh copies of autocomplete.js and common.js from #8a4d2ba but the issue is still happening.

 

When I watch the AJAX calls in the network, the response is coming back fine, so that leads me to suspect the issue is with the JS.  The code is making it through most of the $.fn.autocomplete.ajax loop in common.js (L#219), but the success function (L#229) in that loop is never called.  In autocomplete.js, the code makes it to #L105, but never to #L106 , and so eventho’ the AJAX response is coming back, the autocomplete-results hidden item list is never updated, I think because the createList() function is never called.  


Do you think it would be best to do a full re-install of VuFind 3.1.3, or is there another place I should be looking to figure out why the code’s not working the way it’s supposed to?

 

Thanks,
Leila

 

From: Demian Katz [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 4:53 AM
To: Leila Gonzales; [hidden email]
Subject: Re: [VuFind-Tech] Autocomplete - suggestions not loading

 

Leila,

 

I see that autocomplete is working on the public 3.1.3 demo at https://vufind.org/demo, so I don't think the feature itself is universally broken (unless there is something browser-specific going on). Thus, it may be helpful to narrow down what about your installation is influencing the problem. If you change to the default theme, does the behavior change? Do you see the problem for all types of searches, or just some? Does changing the relevant searches.ini settings here make any difference?

 

https://github.com/vufind-org/vufind/blob/master/config/vufind/searches.ini#L503

 

If you watch the AJAX calls in the network tab of your browser's debugging tool, is there a response coming back? In other words, is the problem that the AJAX call is returning a blank list, or is it that it's returning a valid response and the JS is dropping it for some reason?

 

I hope one of those ideas helps, but if not, please check back in and let us know what you have found so far!

 

thanks,

Demian

 


From: Leila Gonzales <[hidden email]>
Sent: Wednesday, May 10, 2017 8:57 PM
To: [hidden email]
Subject: [VuFind-Tech] Autocomplete - suggestions not loading

 

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Autocomplete - suggestions not loading

Leila Gonzales
In reply to this post by Demian Katz

And… I found the culprit. We were testing setting a session cookie and had added code to our custom module’s Module.config file in the onBootstrap function to set that cookie. When I disable this custom code, the autocomplete functionality works just fine. Just wanted to document this in case anyone else runs into this problem.

 

Thanks again for the tips and help!

-Leila

 

From: Leila Gonzales [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 3:54 PM
To: 'Demian Katz'; '[hidden email]'
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

I did a fresh install of VuFind 3.1.3 and the issue persists, so I’m going to look into the server configuration to see if there’s something there that’s causing the problem. Since the information is being returned in the AJAX call, and I can see it in the browser, there must be something stopping the handoff to the JS file.

 

-Leila

 

From: Leila Gonzales [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 11:52 AM
To: 'Demian Katz'; '[hidden email]'
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

The HTTP status code returns 200 OK. I also tried clearing the cache, restarting apache and also restarting VuFind. No luck. Thanks for asking Chris for ideas too. I’ll keep poking around to see if I can figure this out. Thanks again for the help!

- Leila

 

From: Demian Katz [[hidden email]]
Sent: Thursday, May 11, 2017 11:02 AM
To: Leila Gonzales; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

Is it possible there is something weird going on with the HTTP status code?

I will try to remember to ask Chris for ideas too....

- Demian


From: Leila Gonzales <[hidden email]>
Sent: Thursday, May 11, 2017 11:37:36 AM
To: Demian Katz; [hidden email]
Subject: RE: [VuFind-Tech] Autocomplete - suggestions not loading

 

Thanks for the troubleshooting tips Demian.


I agree this feature isn’t universally broken, as I have it working on another 3.1.3 installation, and as you mention, the demo site works just fine.

 

I’ve tested this on Firefox and Chrome, and the issue persists on both, and if I change the default theme and modules to the base install (bootstrap3 and VuFind), the issue persists. Also, the problem exists for all types of searches and changing the relevant searches.ini settings doesn’t fix the issue.

 

I copied over fresh copies of autocomplete.js and common.js from #8a4d2ba but the issue is still happening.

 

When I watch the AJAX calls in the network, the response is coming back fine, so that leads me to suspect the issue is with the JS.  The code is making it through most of the $.fn.autocomplete.ajax loop in common.js (L#219), but the success function (L#229) in that loop is never called.  In autocomplete.js, the code makes it to #L105, but never to #L106 , and so eventho’ the AJAX response is coming back, the autocomplete-results hidden item list is never updated, I think because the createList() function is never called.  


Do you think it would be best to do a full re-install of VuFind 3.1.3, or is there another place I should be looking to figure out why the code’s not working the way it’s supposed to?

 

Thanks,
Leila

 

From: Demian Katz [mailto:[hidden email]]
Sent: Thursday, May 11, 2017 4:53 AM
To: Leila Gonzales; [hidden email]
Subject: Re: [VuFind-Tech] Autocomplete - suggestions not loading

 

Leila,

 

I see that autocomplete is working on the public 3.1.3 demo at https://vufind.org/demo, so I don't think the feature itself is universally broken (unless there is something browser-specific going on). Thus, it may be helpful to narrow down what about your installation is influencing the problem. If you change to the default theme, does the behavior change? Do you see the problem for all types of searches, or just some? Does changing the relevant searches.ini settings here make any difference?

 

https://github.com/vufind-org/vufind/blob/master/config/vufind/searches.ini#L503

 

If you watch the AJAX calls in the network tab of your browser's debugging tool, is there a response coming back? In other words, is the problem that the AJAX call is returning a blank list, or is it that it's returning a valid response and the JS is dropping it for some reason?

 

I hope one of those ideas helps, but if not, please check back in and let us know what you have found so far!

 

thanks,

Demian

 


From: Leila Gonzales <[hidden email]>
Sent: Wednesday, May 10, 2017 8:57 PM
To: [hidden email]
Subject: [VuFind-Tech] Autocomplete - suggestions not loading

 

Hi all,

 

I'm having some trouble with the autocomplete function on one of my VuFind 3.1.3 installations. What’s happening is that the autocomplete is not populating the search box with suggestions. I've tracked the issue down to the following files:

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/autocomplete.js#L105

https://github.com/vufind-org/vufind/blob/release-3.1/themes/bootstrap3/js/common.js#L219  

 

The autocomplete.js search(input) function passes the query data correctly to the common.js file, which then passes the query parameters correctly onto AjaxController.php which then passes them onto Autocomplete/PluginManager.php and which in turn passes them to Autocomplete/Solr.php.

 

The issue is that the results never come back to the $.fn.autocomplete.ajax function in common.js. (The success function (autocompleteJSON) is not triggered in common.js either). So essentially, the query data gets handed off at autocomplete.js#L105, and nothing comes back, so the rest of the code never gets triggered.

 

I know the breakdown is happening at the point when Autocomplete/Solr.php hands the results back to common.js, but have run out of troubleshooting ideas for how to figure out what and why the break is happening. Thanks for any tips or suggestions you can pass along!

 

- Leila


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Vufind-tech mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/vufind-tech
Loading...