How to handle optional end date in compare clause in meta_query
There is no need to craft a custom SQL query in order to achieve this. Since version 4.1, WordPress’s query classes have supported complex/nested meta queries. So you can craft a query like this: $args[‘meta_query’] = array( // Use an OR relationship between the query in this array and the one in // the next … Read more