Search Divi Plus Documentation

Search for answers or browse our knowledge base.

All Topics
Print

How To Order Posts by Menu in DP Team Slider

To Order the posts by Menu in the DP Team Slider please add this code to your Divi Theme Options

function custom_team_member_order( $query ) {
if ( !is_admin() && $query->get( ‘post_type’ ) == ‘dipl-team-member’ ) {
$query->set( ‘orderby’, ‘menu_order’ );
$query->set( ‘order’, ‘ASC’ );
}
}
add_action( ‘pre_get_posts’, ‘custom_team_member_order’ );

This will arrange your DP Team Members in the slider module in the menu order.

Table of Contents