Search bar not working after plugin upgrade

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Search bar not working after plugin upgrade

This topic contains 4 replies, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 3 months, 3 weeks ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #36374
    bzed82
    bzed82
    Participant

    Hi,

    On my staging site – I upgraded the plugin to latest PRO version, and on the front-end the AJAX feature stopped working on the search bar.
    If before it would open the little box with the results – now it does nothing.

    I am not sure what went wrong or how to fix it.

    Can you assist me ?

    Thank you,
    -Mark

    #36378
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi Mark,

    May I ask how is that search bar placed to the menu?

    I looked in the theme editor in functions.php, and I found a relevant code, however that is not it. If I disable the code the search bar is still present on the page.
    I created a test search bar, and replaced that shortcode with it, and it is working fine. I assume the original search bar is placed there either directly injectin the HTML output of the search or via javascript. In the most recent versions, the HTML output has changed a bit, there is a container element added, without that the plugin can not initialize. In case you are directly outputting the HTML code of the search, then try to capture the new output first. However I do not recommend that method when avoidable, as using the shortcode will always get you the latest output, and it is the only supported use of the plugin search bar.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #36390
    bzed82
    bzed82
    Participant

    Hi Ernest,

    Thank you for replying. I am indeed doing it via Javascript, in order to shift the search bar to be placed in the middle. We have a complicated Menu_Walker to generate the menu (also done with a megamenu plugin).

    Attached a screenshot of the JS code.

    I will follow your guidance to figure out how the new HTML output works.

    Thanks again!

    Attachments:
    You must be logged in to view attached files.
    #36394
    bzed82
    bzed82
    Participant

    Was a quick fix, I just needed to grab the parent element
    var widgetSearch = $(‘#ajaxsearchpro3_1’).parent(),

    Thanks for the assistance!

    #36402
    Ernest Marcinko
    Ernest Marcinko
    Keymaster
    You cannot access this content. Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.