WC_Email::get_content_type()publicWC 1.0

Get email content type.

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

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

Возвращает

Строку.

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

$WC_Email = new WC_Email();
$WC_Email->get_content_type( $default_content_type );
$default_content_type(строка)
Default wp_mail() content type.
По умолчанию: ''

Код WC_Email::get_content_type() WC 8.7.0

public function get_content_type( $default_content_type = '' ) {
	switch ( $this->get_email_type() ) {
		case 'html':
			$content_type = 'text/html';
			break;
		case 'multipart':
			$content_type = 'multipart/alternative';
			break;
		default:
			$content_type = 'text/plain';
			break;
	}

	return apply_filters( 'woocommerce_email_content_type', $content_type, $this, $default_content_type );
}