I'm trying to change the word "category" to the word "client" and "categories" to "clients" on my wordpress site. I would like the change to work in the dashboard, as well as on the categories page.
The information about taxonomies is stored in the global $wp_taxonomies
array.
Since it is a simple array of objects, we can modify it and see what happens. The properties we are interested in are Clients
and Client
.
add_action( 'init', 'Clients_init');
function Clients_init()
{
global $wp_taxonomies;
$wp_taxonomies['category']->labels = (object)array(
'name' => 'Clients',
'menu_name' => 'Clients',
'singular_name' => 'Client',
'search_items' => 'Search Clients',
'popular_items' => 'Popular Clients',
'all_items' => 'All Clients',
'parent_item' => null, // Tags aren't hierarchical
'parent_item_colon' => null,
'edit_item' => 'Edit Client',
'update_item' => 'Update Client',
'add_new_item' => 'Add new Client',
'new_item_name' => 'New Client Name',
'separate_items_with_commas' => 'Separata Clients with commas',
'add_or_remove_items' => 'Add or remove Clients',
'choose_from_most_used' => 'Choose from the most used Clients',
);
$wp_taxonomies['category']->label = 'Clients';
}
Would you please add above code in your current theme function.php
and check it?