Forums Forums Search & Filter Pro Presale date range acf

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

    Hi guys,

    I have a post type with a date field made with ACF.

    I would like to filter these dates based on a user defined date range.

    Is this possible with your plugin? Or is it only possible to select a specific date for ACF fields?

    Regards

    Trevor
    #107168

    You have correctly identified that, at the moment, you can only filter a date range with a date range. It is possible to cheat a bit though. You could add another field to the post with a default date a long way into the future, which would give you a range, which you can then compare to with a range.

    Anonymous
    #107172

    Could you please clarify with an example?

    I have multiple posts with dates in an ACF like so:

    post1 acf_post_date 14/01/2017
    post2 acf_post_date 12/01/2017
    post3 acf_post_date 23/02/2017

    What I would like to happen is that a user can select a date range with a filter e.g.

    10/01/2017 -> 14/01/2017

    And then it should return post1 and post2 but not post 3

    Is this possible with the method you describe?

    Trevor
    #107178

    Actually, try this, without the extra field.

    Go to the post meta field. Set it to Date -> Date Range

    Deselect the Use same for End Key setting and leave both keys as the Start and End keys

    Now you have a new option select box, Compare Mode

    Set that to Post Meta must be within input range

    Does that work?

    Anonymous
    #107198

    Hm I just noticed that the fields are not appearing correctly at all :S

    [IMG]http://i66.tinypic.com/2m61w5e.png[/IMG]

    The standard search form isn’t appearing either :S also without the date field

    I selected post type “products” and woocommerce shop and copied the code in a text widget in the widget area of the shop page but only the titles appear not the actual forms.

    I also tried disabling ajax loading anything else I should try?

    Anonymous
    #107202

    example of titles without fields

    Trevor
    #107206
    This reply has been marked as private.
    Anonymous
    #107218
    This reply has been marked as private.
    Trevor
    #107231
    This reply has been marked as private.
    Trevor
    #107260

    Ok. Great to speak with you. It seems this might be a server configuration issue, so I will wait for you to talk with your hosts about that.

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