WPSEO_Meta_Columns::display_metabox
Wraps the WPSEO_Metabox check to determine whether the metabox should be displayed either by choice of the admin or because the post type is not a public post type.
Метод класса: WPSEO_Meta_Columns{}
Хуков нет.
Возвращает
bool. Whether or not the meta box (and associated columns etc) should be hidden.
Использование
// private - только в коде основоного (родительского) класса $result = $this->display_metabox( $post_type );
- $post_type(строка|null)
- The post type to test.
По умолчанию:current post post_type
Список изменений
| С версии 7.0 | Введена. |
Код WPSEO_Meta_Columns::display_metabox() WPSEO Meta Columns::display metabox Yoast 28.5
private function display_metabox( $post_type = null ) {
$current_post_type = $this->get_current_post_type();
if ( ! isset( $post_type ) && ! empty( $current_post_type ) ) {
$post_type = $current_post_type;
}
return WPSEO_Utils::is_metabox_active( $post_type, 'post_type' );
}