$posts_columns = array
();
$posts_columns['cb'
] = '<input type="checkbox" />';
/* translators: Posts screen column name. */
$posts_columns['title'
] =
_x( 'Title', 'column name'
);
if ( post_type_supports( $post_type, 'author'
) ) { $posts_columns['author'
] =
__( 'Author'
);
} $taxonomies =
get_object_taxonomies( $post_type, 'objects'
);
$taxonomies =
wp_filter_object_list( $taxonomies, array
( 'show_admin_column' => true
), 'and', 'name'
);
/**
* Filters the taxonomy columns in the Posts list table.
*
* The dynamic portion of the hook name, `$post_type`, refers to the post
* type slug.
*
* Possible hook names include:
*
* - `manage_taxonomies_for_post_columns`
* - `manage_taxonomies_for_page_columns`
*
* @since 3.5.0
*
* @param string[] $taxonomies Array of taxonomy names to show columns for.
* @param string $post_type The post type.
*/