Get the child font face post IDs.
$font_family_idintrequired
protected function get_font_face_ids( $font_family_id ) {
$query = new WP_Query(
array(
'fields' => 'ids',
'post_parent' => $font_family_id,
'post_type' => 'wp_font_face',
'posts_per_page' => 99,
'order' => 'ASC',
'orderby' => 'id',
'update_post_meta_cache' => false,
'update_post_term_cache' => false,
)
);
return $query->posts;
}
| Version | Description |
|---|---|
| 6.5.0 | Introduced. |
© 2003–2024 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_rest_font_families_controller/get_font_face_ids