bellows_auto_terms_query_args

bellows_auto_terms_query_args

This filter allows you to filter the get_terms() query arguments for Taxonomy Term Hierarchy Autopopulation menus

$query_args
An array of query arguments to be passed to get_terms(). The filter callback should return $query_args. For a full list of parameters that can be passed, please see The WordPress Codex: WP Term Query Parameters

Example: Exclude specific terms from appearing in menu

The following would exclude terms 22 and 67 from appearing in the menu.

function bam_exclude_terms( $query_args ){
	$query_args['exclude'] = array( 22 , 67 );
	return $query_args;
}
add_filter( 'bellows_auto_terms_query_args' , 'bam_exclude_terms' );

On this page