WC_Query::is_showing_page_on_front() private WC 1.0
Are we currently on the front page?
{} Это метод класса: WC_Query{}
Хуков нет.
Возвращает
true/false.
Использование
// private - только в коде основоного (родительского) класса $result = $this->is_showing_page_on_front( $q );
- $q(WP_Query) (обязательный)
- Query instance.
Код WC_Query::is_showing_page_on_front() WC Query::is showing page on front WC 5.0.0
private function is_showing_page_on_front( $q ) {
return ( $q->is_home() && ! $q->is_posts_page ) && 'page' === get_option( 'show_on_front' );
}