Automattic\WooCommerce\Internal\EmailEditor\WCTransactionalEmails

WCTransactionalEmailPostsManager::get_cache_key_for_post_id │ public │ WC 1.0

Gets the cache key for a specific post ID.

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

Хуков нет.

Возвращает

string. The cache key e.g. 'post_id_to_email_type_123'.

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

$WCTransactionalEmailPostsManager = new WCTransactionalEmailPostsManager();
$WCTransactionalEmailPostsManager->get_cache_key_for_post_id( $post_id );
$post_id(int) (обязательный)
The post ID.

Код WCTransactionalEmailPostsManager::get_cache_key_for_post_id() WC 11.2.2

public function get_cache_key_for_post_id( $post_id ) {
	return 'post_id_to_email_type_' . $post_id;
}