Support » Plugin: Relevanssi Live Ajax Search » No Ajax Search Results Show

  • Resolved atait488

    (@atait488)


    I’ve installed your plugin with Relevanssi, Woocommerce and Storefront Theme. As there are no setup pages it should just work but nothing shows up around the search box when I start to type a known product page. I’ve used basic Relevanssi for years and it works fine. I can’t see anything in your documentation page. What am I doing wrong? The page link above is just the test site.
    Andy

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Mikko Saari

    (@msaari)

    Storefront uses the WooCommerce product search widget that Relevanssi Live Ajax Search can’t automatically take over.

    I can fix this for the next version of Relevanssi Live Ajax Search, meanwhile you can add this snippet to your site to fix this problem:

    add_filter( 'get_product_search_form', function( $form ) {
    	$form = str_replace( 'name="s"', 'name="s" data-rlvlive="true" data-rlvconfig="default"', $form );
    	return $form;
    } );

    Alternatively you can replace the file /includes/class-relevanssi-live-search-form.php with this file.

    Storefront also requires you to use the less-accessible result display. Add this to your site:

    add_filter( 'relevanssi_live_search_add_result_div', '__return_false' );

    Thread Starter atait488

    (@atait488)

    Thanks Mikko. Both of those methods work and give live search results. Andy.

    So, on a related theme. I’m using a WP Bakery based theme. The standard WP Search works for the Relevanssi search plugin, but isn’t showing results for the ajax live search.

    Is there a version of the snippet above that would work for that?

    Plugin Author Mikko Saari

    (@msaari)

    Please start a new thread for your question; this thread is already marked resolved, and your question isn’t related to the topic (Storefront and WooCommerce).

    Check where the search fails:

    1. The search form is missing data-rlvlive="true" data attribute.
    2. The attribute is there, but the #rlvlive_1 results element is empty.
    3. The attribute is there and the results appear in the element, but the element isn’t visible to users.

    Please report your findings in the new thread.

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