Support Forums

Looking for support? You can access the support system via your account.

Forums Forums Search & Filter Pro Search options not working with ACF

Viewing 10 posts - 1 through 10 (of 13 total)
  • Aline Gustafsson
    #217566

    Hello!

    I have set up ACF criteria and set up a test search with some of the criteria, but the outcome is that the choices return: field_5d3eeab5af1f0

    You can have a look here: https://nordsip.com/test-search-page/

    There must be something I am missing. Could you please help?

    Thanks!

    Aline

    Trevor Moderator
    #217575

    In selecting the Meta Key name, note a ‘gotcha’ with ACF ….

    … it makes 3 meta keys per field, like this (in this example for a field named ‘Theme’):

    #1 _theme
    #2 field_5d3eeab5af1f0
    #3 theme

    In our Post Meta form object Meta Key selection list, you need to use key #3, without the underscore at the start of the key name. If you choose #1 by mistake, in the field choices you will see the name of #2.

    Aline Gustafsson
    #217608

    Thanks Trevor!

    Something changed, so this is definitely the right track. However, the search indicates (0) posts identified (I did update the cache twice to make sure). There are definitely several posts where I have selected those options. I have also changed fields so see if it worked with other fields, but it didn’t.

    Could you tell me what this could be due to?

    Thanks again!

    Trevor Moderator
    #217610
    This reply has been marked as private.
    Aline Gustafsson
    #217635
    This reply has been marked as private.
    Trevor Moderator
    #217675
    This reply has been marked as private.
    Aline Gustafsson
    #217752
    This reply has been marked as private.
    Jordan
    #217760

    Trevor – Question regarding your notes on selecting the correct ACF meta key:
    https://support.searchandfilter.com/forums/topic/search-options-not-working-with-acf/#post-217575

    In our Post Meta form object Meta Key selection list, you need to use key #3

    Should we also be using the non underscore keys when we’re modifying the query via sf_edit_query_args too?

    Trevor Moderator
    #217762

    I believe so, yes.

    Aline Gustafsson
    #217799
    This reply has been marked as private.
Viewing 10 posts - 1 through 10 (of 13 total)

The topic ‘Search options not working with ACF’ is closed to new replies.