Support Forums

The forums are closed and will be removed when we launch our new site.

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

Forums Forums Search & Filter Pro Fields with similar labels

Viewing 5 posts - 1 through 5 (of 5 total)
  • Steven
    #18995

    I have two fields that have nearly identical labels: “World War I” and “World War II”. When I select the WWII filter it correctly displays just WWII items, however, when I select the WWI filter it displays both WWI and WWII.

    Is there any way to force these parameters to accept only exact matches?

    Another question, a little off topic, is can I display headers on my results page (using ajax and archive page) depending on what filters are selected?

    Thanks!

    Ross Moderator
    #19050

    Hi Steven

    In regards to your first point – do you have a link I could look at?

    RE the second, its possible to filter through the query to get this data – however I’m working on a feature where you will have access to some simple functions to achieve that – I can dig the code out or would you prefer to wait for the feature?

    Thanks

    Steven
    #19076
    This reply has been marked as private.
    Ross Moderator
    #19412

    Hi Steven

    To answer your questions.

    What may be happening is if the post meta data is serialised then the only way to search this in the database is to use a %LIKE% compare… in MySQL.

    Please see this post for more in depth info on how this currently works

    Actually, the next version of S&F will likely create a sort of cache for all this info, and I’m hoping that this problem therefore won’t exist (and the search queries will be much faster) but I’m still working through this atm as its not finalised.

    You could alternatively create a custom taxonomy where this issue would not occur.

    RE your other question, here is a function I wrote to grab taxonomy information from the search (wp_query object)

    https://support.searchandfilter.com/forums/topic/how-to-show-cats-title-in-search-result/#post-13653

    And here is post for grabbing ACF data:

    https://support.searchandfilter.com/forums/topic/showing-results-under-x-and-y-and-z/#post-14966

    Thanks

    Steven
    #19456

    For now I implemented a custom taxonomy.

    Looking forward to 2.0!

    Thanks, Ross!

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

The forum ‘Search & Filter Pro’ is closed to new topics and replies.