Order post type archive pages by menu order for use with sort order plugins.
<?php
function ccd_query_vars( $query ) {
if ( ! is_admin() && $query->is_main_query() && is_post_type_archive( 'post_type_slug' ) ) {
$query->set( 'orderby', 'menu_order' );
$query->set( 'order', 'ASC' );
return $query;
}
return $query;
}
add_action( 'parse_query', 'ccd_query_vars' );
?>
WordPress Snippet