REFACTOR Commenting now useless default post-type rename
This commit is contained in:
parent
e90d7edb76
commit
0ce4a8bf36
|
|
@ -245,30 +245,30 @@ add_action('init', 'carhop_register_taxonomies', 0);
|
|||
/* ------------------------------------------------
|
||||
##### CHANGE LE NOM DES POSTS PAR ACTUALITES
|
||||
--------------------------------------------------*/
|
||||
function carhop_change_post_object()
|
||||
{
|
||||
$current_site = get_current_blog_id();
|
||||
if ($current_site !== 1) return;
|
||||
// function carhop_change_post_object()
|
||||
// {
|
||||
// $current_site = get_current_blog_id();
|
||||
// if ($current_site !== 1) return;
|
||||
|
||||
$get_post_type = get_post_type_object('post');
|
||||
$labels = $get_post_type->labels;
|
||||
$labels->name = 'Actualités';
|
||||
$labels->singular_name = 'Actualité';
|
||||
$labels->add_new = 'Ajouter une actualité';
|
||||
$labels->add_new_item = 'Ajouter une nouvelle actualité';
|
||||
$labels->edit_item = 'Editer l\'actualité';
|
||||
$labels->new_item = 'Actualité';
|
||||
$labels->view_item = 'Voir l\'actualité';
|
||||
$labels->search_items = 'Chercher une actualité';
|
||||
$labels->not_found = 'Pas d\'actualité trouvée';
|
||||
$labels->not_found_in_trash = 'Pas d\'actualité trouvée dans la corbeille';
|
||||
$labels->all_items = 'Toutes les actualités';
|
||||
$labels->menu_name = 'Actualités';
|
||||
$labels->name_admin_bar = 'Actualités';
|
||||
// $get_post_type = get_post_type_object('post');
|
||||
// $labels = $get_post_type->labels;
|
||||
// $labels->name = 'Actualités';
|
||||
// $labels->singular_name = 'Actualité';
|
||||
// $labels->add_new = 'Ajouter une actualité';
|
||||
// $labels->add_new_item = 'Ajouter une nouvelle actualité';
|
||||
// $labels->edit_item = 'Editer l\'actualité';
|
||||
// $labels->new_item = 'Actualité';
|
||||
// $labels->view_item = 'Voir l\'actualité';
|
||||
// $labels->search_items = 'Chercher une actualité';
|
||||
// $labels->not_found = 'Pas d\'actualité trouvée';
|
||||
// $labels->not_found_in_trash = 'Pas d\'actualité trouvée dans la corbeille';
|
||||
// $labels->all_items = 'Toutes les actualités';
|
||||
// $labels->menu_name = 'Actualités';
|
||||
// $labels->name_admin_bar = 'Actualités';
|
||||
|
||||
// remove_post_type_support('post', 'editor');
|
||||
unregister_taxonomy_for_object_type('category', 'post');
|
||||
unregister_taxonomy_for_object_type('post_tag', 'post');
|
||||
}
|
||||
// // remove_post_type_support('post', 'editor');
|
||||
// unregister_taxonomy_for_object_type('category', 'post');
|
||||
// unregister_taxonomy_for_object_type('post_tag', 'post');
|
||||
// }
|
||||
|
||||
add_action('init', 'carhop_change_post_object');
|
||||
// add_action('init', 'carhop_change_post_object');
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user