Answer the question
In order to leave comments, you need to log in
How to get 'name' from get_tags() in WP Rest Api?
Like in this code:
register_rest_field( 'post', 'GetTags', array(
'get_callback' => function ( $data ) {
return get_tags( $data['id'], '', '');
}, ));
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question