Home › Forums › Front-end Issues › Custom Post List filtered by ACF criteria › Reply To: Custom Post List filtered by ACF criteria
Thanks for your quick reply.
I gave your idea a go but I am not sure how to incorporate the meta_key “start_date” into the equation – could you elaborate. Perhaps I don’t need it as I am not using an ACF start date but the original “published” date.
I have tried to use the following but with no success (I simplified the fields I am using):
$args = array( 'paged' => $paged, 'post_type' => 'feature', 'orderby' => 'meta_value_num', 'meta_query' => array( 'relation' => 'AND', array( 'orderby' => array( 'published' => 'DESC' , 'hide_from_archive' != '1' )) ) ); $wp_query = new WP_query(); $wp_query->query($args);
Thanks again for your advice.
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’re reaching out to our multilingual users to ask for help in translating ACF 6.1. Help make sure the latest features are available in your language here: https://t.co/TkEc2Exd6U— Advanced Custom Fields (@wp_acf) May 22, 2023
© 2023 Advanced Custom Fields.