Yoast\WP\SEO\Dashboard\Application\Content_Types
Content_Types_Repository::get_content_types()
Returns the content types array.
Метод класса: Content_Types_Repository{}
Хуков нет.
Возвращает
Массив<Массив<Строку,Массив<Строку,
. array<string, array<string, string|null>>>>> The content types array.
Использование
$Content_Types_Repository = new Content_Types_Repository(); $Content_Types_Repository->get_content_types(): array;
Код Content_Types_Repository::get_content_types() Content Types Repository::get content types Yoast 24.3
public function get_content_types(): array { $content_types_list = $this->content_types_collector->get_content_types(); foreach ( $content_types_list->get() as $content_type ) { $content_type_taxonomy = $this->taxonomies_repository->get_content_type_taxonomy( $content_type->get_name() ); $content_type->set_taxonomy( $content_type_taxonomy ); } return $content_types_list->to_array(); }