WP_REST_Font_Families_Controller::get_font_face_ids
Get the child font face post IDs.
Метод класса: WP_REST_Font_Families_Controller{}
Хуков нет.
Возвращает
int[]. Array of child font face post IDs.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->get_font_face_ids( $font_family_id );
- $font_family_id(int) (обязательный)
- Font family post ID.
Список изменений
| С версии 6.5.0 | Введена. |
Код WP_REST_Font_Families_Controller::get_font_face_ids() WP REST Font Families Controller::get font face ids WP 6.9.1
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;
}