Add columns to a WordPress taxonomy terms table

At times, you might find it useful to add an extra column in the tags table under Posts->Tags.

Here’s how you can insert columns and add content to each term row. Add this to your theme functions.php file.

function add_post_tag_columns($columns){
    $columns['foo'] = 'Foo';
    return $columns;
}
add_filter('manage_edit-post_tag_columns', 'add_post_tag_columns');

function add_post_tag_column_content($content){
    $content .= "Bar";
    return $content;
}
add_filter('manage_post_tag_custom_column', 'add_post_tag_column_content');

You can also replace ‘post_tag’ with your custom taxonomy slug to make this work anywhere.