Custom search filters

This topic contains 3 replies, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 4 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #47018
    collin43
    collin43
    Participant

    Hi!

    I have a question regarding the following.

    I get the price range slider to work, as it makes sense, in ACF I have filled in for example “10.000”, and when that value is in between the sliders (so for example between 8000 and 15.000), it shows, as it falls “in the range”.

    I have trouble setting up other filters. I am making a website where people can find wedding venues.

    One part of the filter is the capacity of a wedding venue in terms of people that can come.

    A venue could have a max capacity of for example:
    Wedding ceremony: max capacity “60” people.
    Diner: max capacity of “80” people
    Party: max capacity of “150” people.

    Where in the brackets number, that number is storedd in ACF.

    But when I try to do a slider, where people put in how many people they expect at the ceremony / diner / party, I am not getting it to work. I tried playing with the “less then” and “less and equal” operators, but I think i’m “thinking” wrong about it.

    What I do not get to work is that any value below “max capacity” is allowed / valid to show as a result.

    So in the example above, the max capacity of the party is 150, but when someone puts in 80 as their party group, the 150 is “valid”, as 80 people fit in a 150 capacity venue.

    Can you help me on my way? Because right now, when people put in 80, it does not show the locations that have more than enough capacity.

    Thanks 🙂 !

    #47021
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi,

    Sure!

    Okay, so in this case the best option is to use a “MORE OR EQUALS THEN” operator, as you want to show venues which have more capacity as the user input: https://i.imgur.com/fyA4MMr.png

    So say they input 100 and the capacity of a venue is 180, then it passes as 180 is more or equals than 100.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #47026
    collin43
    collin43
    Participant

    Ahhh…… So I was thinking exactly the wrong way with that it should be less.

    Thank you! Working great now 🙂 It’s fun to learn new things haha, thanks!

    #47028
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    It’s all right, it is easy to get confused 🙂

    If you don’t mind, I will close this topic soon and mark it as resolved, feel free to open another one if you have other questions or issues.

    If you like the plugin and have not rated already, feel free to leave a rating on your codecanyon downloads page and on the wordpress plugin repository, it’s greatly appreciated.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


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

You must be logged in to reply to this topic.