WP カテゴリ一覧 親のみ、特定カテゴリ複数削除
<?php $args = array( 'orderby' => 'name', 'parent' => 0, //第一階層 'exclude' => array(8,9), // '8,9'でもよい ); $categories = get_categories( $args ); foreach ( $categories as $category ) { echo '<a href="' . get_category_link( $category->term_id ) . '">' . $category->name . '</a><br/>'; } ?>
参考は下記