ORDER BY custom field value
You can create groups of meta_queries using specific compare operation on them, and since you want to order based in a single custom field, you can keep the order declaration dedicated to the single meta field. So: $q = new WP_Query( array( ‘meta_key’ => ‘population’, //setting the meta_key which will be used to order ‘orderby’ … Read more