Home › Forums › General Issues › 2 pre_get_posts functions to filter by custom fields › Reply To: 2 pre_get_posts functions to filter by custom fields
Hi,
I have created a custom post type on my website – event – and am trying to work out how to filter category pages for events so that only current/future event posts appear on the category pages (I have an ACF datetime field for events). Your post is the closest I have seen to a possible solution, as I think I need to use pre_get_posts but am in over my head a bit. Am I right in thinking I could alter what you have done here a bit to get the results I need?
Thanks
John
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.