Is it possible to sort pages in the loop using the admin's order field (under page attributes)?
1 Answer
Yes, use the orderby
and order
clause in your query posts.
query_posts( array('orderby'=>'menu_order', 'order' => 'ASC' ) );
See: WP_Query#Order for reference
-
3Please note that you also need to use
order
argument, example:'order' => 'ASC'
. Dec 29, 2015 at 18:43