Support » Plugin: WP Search with Algolia » The search isn’t working in the product page

  • Resolved davidem82

    (@davidem82)


    Hi,

    the search is working in all the pages but in the single product page, not.
    Any idea?

    Thanks.
    Davide

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author Michael Beckwith

    (@tw2113)

    The BenchPresser

    Hi @davidem82

    Can you provide a link to the site in question? Shouldn’t be any sort of restrictions, but I’m wondering if perhaps some sort of javascript error is occurring on just the single product pages to prevent the results from showing like needed.

    Thread Starter davidem82

    (@davidem82)

    Hi Micheal,

    sure, you can check it here:
    https://www.fabioferro.eu

    Thanks a lot.

    Regards.
    Davide

    Plugin Author Michael Beckwith

    (@tw2113)

    The BenchPresser

    Hey Davide,

    Have you done any sort of template customizations or perhaps optimization of some sort regarding script loading?

    On a single product page, I’m seeing this error in the browser developer tools console:

    Uncaught TypeError: wp.template is not a function
    fope-bracelet-woman-small-collection-in-white-gold.html:3127:33

    This tells me that either things are trying to run too early, or something isn’t quite available yet, especially around the WordPress utility script that provides the wp.template function.

    Thread Starter davidem82

    (@davidem82)

    Hi Micheal,

    Thank you very much for your reply.
    Yes, I’m sorting products by availability.

    Do you have any idea on How I can solve this having both features?

    Thanks a lot.
    Davide

    • This reply was modified 4 months, 3 weeks ago by davidem82.
    • This reply was modified 4 months, 3 weeks ago by davidem82.
    Plugin Author Michael Beckwith

    (@tw2113)

    The BenchPresser

    This isn’t anything to do with the products displayed or how, this is in regards to the javascript libraries loaded with the page to make the autocomplete work.

    So this would be any sort of caching plugins that let you dictate when script files are loaded, or any sort of combining of the files into fewer requests. If you’ve done customization of the templates themselves, there would be an “algolia” folder in your theme folder with the customized copies.

    Thread Starter davidem82

    (@davidem82)

    I’ve just override the autocomplete to show the sku and I removed the short description to the preview of the results.

    • This reply was modified 4 months, 3 weeks ago by davidem82.
    • This reply was modified 4 months, 3 weeks ago by davidem82.
    Plugin Author Michael Beckwith

    (@tw2113)

    The BenchPresser

    There isn’t really any edit to the plugin we can do on our end without ending up affecting everyone. I am curious if it would all work again if you returned back to the defaults. You should be able to just temporarily rename the algolia folder in the theme, to anything else, and those would no longer get picked up.

    We have the why, regardless, just a matter of why it’s only error-ing in some places.

    Thread Starter davidem82

    (@davidem82)

    Hi Micheal,

    there is a very strange thing. I didn’t nothing and now it works!
    Bah!

    Thanks for your support!

    Plugin Author Michael Beckwith

    (@tw2113)

    The BenchPresser

    Welcome.

Viewing 9 replies - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.