Automattic\WooCommerce\Blocks\Templates

AbstractPageTemplate::page_template_title()publicWC 1.0

Forces the page title to match the template title when this template is active.

Only applies when hooked into pre_get_document_title. Most templates used for pages will not require this because the page title should be used instead.

Method of the class: AbstractPageTemplate{}

No Hooks.

Return

String.

Usage

$AbstractPageTemplate = new AbstractPageTemplate();
$AbstractPageTemplate->page_template_title( $title );
$title(string) (required)
Page title.

AbstractPageTemplate::page_template_title() code WC 9.6.1

public function page_template_title( $title ) {
	if ( $this->is_active_template() && $this->get_template_title() ) {
		return $this->get_template_title();
	}
	return $title;
}