However, that code is blocking other posts and pages on my site and showing ONLY Event Espresso event. You can see the result here: https://theeastaging.wpengine.com/?s=HR
How can I hide expired events yet include other posts and pages on the site?
I think you’ll need a separate search field for events to accomplish this. The reason being is the filters that can be added to the query get added before the query. In other words, we can tell the query to filter away expired events but there isn’t a way to tell the query to only apply those filters to only some of the results.
The support post ‘Expired events in website global search’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.
Support forum for Event Espresso 3 and Event Espresso 4.