WC_Session_Handler::use_secure_cookie │ protected │ WC 3.6.0

Should the session cookie be secure?

Метод класса: WC_Session_Handler{}

Хуки из метода

Возвращает

bool.

Использование

// protected - в коде основоного (родительского) или дочернего класса
$result = $this->use_secure_cookie();

Список изменений

С версии 3.6.0 Введена.

Код WC_Session_Handler::use_secure_cookie() WC 11.2.2

protected function use_secure_cookie() {
	/**
	 * Filter whether to use a secure cookie.
	 *
	 * @since 3.6.0
	 *
	 * @param bool $use_secure_cookie Whether to use a secure cookie.
	 */
	return (bool) apply_filters( 'wc_session_use_secure_cookie', wc_site_is_https() && is_ssl() );
}