How to decrease the number of queries with get_posts and ACF?

It’s everything OK with get_posts() since it creates the single WP_Query instance per call. You can check the query by creating that instance: <?php $test_query = new WP_Query( array( ‘post_type’ => ‘post’, ‘posts_per_page’ => -1, // any number, does not matter ‘post__in’ => $ids, // should be an array! ) ); echo $test_query->request; Adding ‘meta_query’ … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)