list_table_primary_column
Filters the name of the primary column for the current list table.
Usage
add_filter( 'list_table_primary_column', 'wp_kama_list_table_primary_column_filter', 10, 2 ); /** * Function for `list_table_primary_column` filter-hook. * * @param string $default Column name default for the specific list table, e.g. 'name'. * @param string $context Screen ID for specific list table, e.g. 'plugins'. * * @return string */ function wp_kama_list_table_primary_column_filter( $default, $context ){ // filter... return $default; }
- $default(string)
- Column name default for the specific list table, e.g. 'name'.
- $context(string)
- Screen ID for specific list table, e.g. 'plugins'.
Changelog
Since 4.3.0 | Introduced. |
Where the hook is called
list_table_primary_column
wp-admin/includes/class-wp-list-table.php 1287
$column = apply_filters( 'list_table_primary_column', $default, $this->screen->id );