Forums Forums Search & Filter Pro Issue to sort with custom archive template in Elementor Pro

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

    Hi,
    I think my issue is closed to this topic (https://support.searchandfilter.com/forums/topic/acf-and-cpt-archive-with-custom-loop/) but most of the replies are private.
    I’m doing a real estate website using CTP (with CPT UI and ACF). It’s build with Elementor Pro and Ele Custom Skin (https://wordpress.org/plugins/ele-custom-skin/).

    On my archive page, I want to sort properties by price, which is a custom field. I’m using the Elementor Posts Widget but the Classical skin and the Cards skin don’t allow to add custom fields.
    That why I use Ele Custom Skin which allows to create custom template with custom fields and to insert it in the Post Widget.

    My issue: the sort doesn’t work with this custom skin although it works with the Classic skin.
    See my page: https://www.nicolas-devillard.fr/ndiv2/category/location/
    Just below the dropdown sorting menu, the posts widget using the Classic skin (I just displayed the minimum info with minimum design just to test).
    After, you can see the wanted posts widget using the custom skin and displaying custom fields including price.

    Because I can see the different sorts with the Classic Posts Widget (prices aren’t displayed but I can see the different sortings and verify it’s good), I know my S&F settings are good . And I can see it doesn’t work at all with my custom skin (I also did tests with the page only withe my custom skin and without the Classic skin to be sure there is no interference).

    Any ideas to fix this?
    Best,

    David

    Trevor
    #214030
    This reply has been marked as private.
    Anonymous
    #214042
    This reply has been marked as private.
    Trevor
    #214047
    This reply has been marked as private.
    Anonymous
    #214063
    This reply has been marked as private.
    Trevor
    #214221
    This reply has been marked as private.
    Anonymous
    #214335

    Hi,
    This setting doesn’t change anything.

    But I create a second ACF field for the Price as a number field type (the first one is a text field type because I need to display it with separator (dot) on my listings).
    I also tried to deactivate Advanced Post Type Order plugin (https://www.nsp-code.com/premium-plugins/wordpress-plugins/advanced-post-types-order/)
    And with this two changes, it works.
    But I need to use Advanced PTO because I can’t let the properties be organized by date.
    It seems like PTO has priority over your plugin and prevents his functioning

    On my current website (not the same theme, no Elementor, not your plugin), but I can use both PTO and a sort by price that is embedded
    in the theme (https://www.nicolas-devillard.fr/en/property-category/location-general/).

    Could it be possible to have Advanced PTO and your plugin works together?
    The default sort on the page opening has to be the PTO manual sort and I offer to option to sort by prices.

    Best,

    David

    Trevor
    #214360

    Ah. The Advanced Post Types order plugin uses pre_get_posts to override our query (many plugin like it do the same) and so it could cause many problems with search settings. That type of plugin is always likely to conflict with any search plugin that has sort options.

    Anonymous
    #214381

    I see.
    I’m not a developper, but could we imagine a way to stop or deactivate pre_get_posts when your query are loaded?
    If so, could you provide this development?

    Trevor
    #214385

    I do not think that is possible. Instead, there must be another way to custom sort the posts on first page load. How many posts does this affect, and do the posts change over time, and how/why?

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