API – Translation for CPT
-
Hello,
I have created a Custom Post Type “faq” in my function.php, I can translate it, but when I go to the https://www.myafterme.com/en/wp-json/wp/v2/faq/91 I cannot get the translation. Do I miss something ? I cannot find any anwser to my question.
$labels = array( 'name' => 'Foire aux questions', 'singular_name' => 'Question fréquente', 'menu_name' => 'FAQ', 'name_admin_bar' => 'Question fréquente', 'add_new' => 'Ajouter', 'add_new_item' => 'Ajouter une nouvelle question fréquente', 'new_item' => 'Nouvelle question fréquente', 'edit_item' => 'Éditer la question fréquente', 'view_item' => 'Voir la question fréquente', 'all_items' => 'Toutes les questions fréquentes', 'search_items' => 'Rechercher des questions fréquentes', 'parent_item_colon' => 'Question fréquente parente :', 'not_found' => 'Aucune question fréquente trouvée.', 'not_found_in_trash' => 'Aucune question fréquente trouvée dans la corbeille.' ); $args = array( 'labels' => $labels, 'public' => true, 'publicly_queryable' => true, 'show_ui' => true, 'show_in_menu' => true, 'show_in_rest' => true, 'query_var' => false, 'capability_type' => 'post', 'has_archive' => false, 'hierarchical' => false, 'menu_position' => null, 'rewrite' => array('slug' => 'faq'), 'supports' => array('title', 'thumbnail','editor'), 'menu_icon' => 'dashicons-testimonial', ); register_post_type('faq', $args);Best regards
The page I need help with: [log in to see the link]
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
The topic ‘API – Translation for CPT’ is closed to new replies.