Forums Forums Search & Filter Pro Search filter disappear

Viewing 10 posts - 1 through 10 (of 10 total)
  • Anonymous
    #106052

    Hi,

    I’m having a problem setting up the filters. Once I have selected my search criterias, the page refreshes automatically showing the results (which is correct) but I lose all filters and I can’t do other search.

    It’s like if the site redirects to another page with only the results, and what I want is to update the same page with the results.

    Is that possible ?

    Thanks

    Trevor
    #106151

    Can you send me a link (URL) to the page with the search form on?

    Anonymous
    #106204

    Hi Trevor,

    I think I have solved the problem using a shortcode. Now I can keep the search form and the results are shown on the same page.

    However doing that I’m not able to customize the appearance of the results, they are shown like a list of posts. Is there any (easy) way to show the results in a grid ?

    Thanks

    Trevor
    #106209

    The answer to that is dependent on what theme you are using and/or if you have Visual Composer.

    Anonymous
    #106259
    This reply has been marked as private.
    Trevor
    #106264

    That information does help me yes, and might make it possible for a solution. What page is the search form on? I do not see it on the home page?

    Anonymous
    #106269
    This reply has been marked as private.
    Trevor
    #106302

    That page seems to work OK for me, but is not using an Ajax refresh. I must press ‘Enviar’ first. The URL does not contain the search term though. This may be because you have (and should not I think) Maintain Search Form State ON. Please try changing this.

    Anonymous
    #106431
    This reply has been marked as private.
    Trevor
    #106505

    About grids. I would need you to find some information out about the Flatsome UX Builder. It is possible a new feature in Search Filter Pro would allow a grid made by it to work directly with our filter, but …

    I assume that the grid that it builds has ‘masonry’-like behaviour. Masonry/Isotope and Salvattore are the most popular commercial scripts out there used by WordPress themes. For example, Divi uses Salvattore and Avada uses Masonry. I cannot see that Flatsome uses either.

    The issue with grids is when you trigger a ‘posts reload’ with our filter and Ajax, the grid script needs to re-trigger. This requires the theme author to provide that code. Then you load a script on to the page to do that. This is an example of the script required for Divi with Search & Filter pro:

    <script>(function ( $ ) {
      "use strict";
      $(document).on("sf:ajaxfinish", ".searchandfilter", function(){
        console.log("ajax complete");
        var grids = document.getElementsByClassName('et_pb_blog_grid');
        salvattore['register_grid'](grids[0]);
      });
    }(jQuery));</script>

    Where these lines are what we worked out were required to re-trigger Salvattore in Divi (Divi could not tell us, but we managed to work it out for ourselves):

    var grids = document.getElementsByClassName('et_pb_blog_grid');
    salvattore['register_grid'](grids[0]);

    Masonry is far harder to figure and really needs the theme author to help.

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