$conf, $runtime; function_exists('chdir') AND chdir(APP_PATH); $r = 'mysql' == $conf['cache']['type'] ? website_set('runtime', $runtime) : cache_set('runtime', $runtime); } function runtime_truncate() { global $conf; 'mysql' == $conf['cache']['type'] ? website_set('runtime', '') : cache_delete('runtime'); } register_shutdown_function('runtime_save'); ?>plugin development - Change Label of custom post type|Programmer puzzle solving
最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

plugin development - Change Label of custom post type

matteradmin12PV0评论

I have created a custom post type by the name of Teams. Listing page looks like this

How can I change this highlighted title label?

Is there any hook for this that you know of?

I have created a custom post type by the name of Teams. Listing page looks like this

How can I change this highlighted title label?

Is there any hook for this that you know of?

Share Improve this question asked Oct 30, 2018 at 17:26 user9258337user9258337 111 bronze badge
Add a comment  | 

1 Answer 1

Reset to default 1

The list_table_primary_column hook might be the one to go with, i.e:

add_filter('list_table_primary_column', 'teams_table_primary_column', 10, 2);

function teams_table_primary_column($colname, $screen_id) {
    if($screen_id == 'teams' && $colname == 'Title') {
        return "New column name";
    }
}

Note: this is completely untested, let me know how it goes!

Reference

Post a comment

comment list (0)

  1. No comments so far