WPSEO_Metabox::determine_scope
Determines the scope based on the post type. This can be used by the replacevar plugin to determine if a replacement needs to be executed.
Метод класса: WPSEO_Metabox{}
Хуков нет.
Возвращает
Строку. String describing the current scope.
Использование
// private - только в коде основоного (родительского) класса $result = $this->determine_scope();
Код WPSEO_Metabox::determine_scope() WPSEO Metabox::determine scope Yoast 27.5
private function determine_scope() {
if ( $this->get_metabox_post()->post_type === 'page' ) {
return 'page';
}
return 'post';
}