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

    (@msaari)

    Flatsome already has a built-in method of replacing the AJAX search used, so they’ve already thought of this. Because of that, I don’t think they’re going to add built-in support for Relevanssi as why would they? Their current solution covers all existing and future third-party search tools.

    I already had this solution for enabling Relevanssi with Flatsome:

    function rlv_flatsome_search_function( $query, $args, $defaults ) {
      $args['relevanssi'] = true;
      return get_posts( $args );
    }
    
    add_filter( 'flatsome_ajax_search_function', function() { return 'rlv_flatsome_search_function'; } );

    How is your solution related to this? Does your solution work in some cases where this one doesn’t? I can post your solution to my Flatsome knowledge base page.

    Thread Starter Marco Almeida | Webdados

    (@webdados)

    I tried that flatsome_ajax_search_function approach but didn’t knew that I could just add tha argument relevanssi to true.

    I don’t think it will be many different using my solution or yours, it’s basically doing the same thing: forcing Relevanssi to do its thing.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Relevanssi + Flatsome Ajax Search’ is closed to new replies.