• I’m trying to get sorted terms from a custom taxonomy. The backend interface lets me sort the terms just fine, but when using code to fetch them, they’re not in the right order to match the backend ordering.

    
    
    <?php
    $my_custom_terms = new WP_Term_Query( [
    	'taxonomy' 		=> 'my_custom_taxonomy',
    	'order'    		=> 'ASC',
    	'orderby'  		=> 'menu_order',
    	'child_of'      => 0,
        'parent'        => 0,
        'fields'        => 'all',
        'hide_empty'    => true
    ] );

    Am I going about this wrong? Thanks for your help!

  • The topic ‘Unable to reorder terms in custom taxonomy’ is closed to new replies.