WordPress Hooks Explorer

Listing all hooks extracted WordPress Core

Details about wp_mail_content_type

Back to home


Filename Hook Type Line Number PHP Doc
wp-includes/formatting.php apply_filters 5996 /**
* Converts emoji in emails into static images.
* @since 4.2.0
* @param array $mail The email data array.
* @return array The email data array, with emoji in the message staticized.
function wp_staticize_emoji_for_email( $mail ) {
if ( ! isset( $mail['message'] ) ) {
return $mail;

* We can only transform the emoji into images if it's a `text/html` email.
* To do that, here's a cut down version of the same process that happens
* in wp_mail() - get the `Content-Type` from the headers, if there is one,
* then pass it through the {@see 'wp_mail_content_type'} filter, in case
* a plugin is handling changing the `Content-Type`.
wp-includes/pluggable.php apply_filters 478 /**
* Filters the wp_mail() content type.
* @since 2.3.0
* @param string $content_type Default wp_mail() content type.

Hook Parameters

Parameter Type Name Description
string $content_type Default wp_mail() content type.