network_admin_email_change_email хук-фильтрWP 4.9.0

Filters the contents of the email notification sent when the network admin email address is changed.

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

add_filter( 'network_admin_email_change_email', 'wp_kama_network_admin_email_change_filter', 10, 4 );

/**
 * Function for `network_admin_email_change_email` filter-hook.
 * 
 * @param array  $email_change_email Used to build wp_mail().
 * @param string $old_email          The old network admin email address.
 * @param string $new_email          The new network admin email address.
 * @param int    $network_id         ID of the network.
 *
 * @return array
 */
function wp_kama_network_admin_email_change_filter( $email_change_email, $old_email, $new_email, $network_id ){

	// filter...
	return $email_change_email;
}
$email_change_email(массив)

Used to build wp_mail().

  • to(строка)
    The intended recipient.

  • subject(строка)
    The subject of the email.

  • message(строка)
    The content of the email.

    The following strings have a special meaning and will get replaced dynamically:
    
    - ###OLD_EMAIL### The old network admin email address.
    - ###NEW_EMAIL### The new network admin email address.
    - ###SITENAME###  The name of the network.
    - ###SITEURL###   The URL to the site.
    
  • headers(строка)
    Headers.
$old_email(строка)
The old network admin email address.
$new_email(строка)
The new network admin email address.
$network_id(int)
ID of the network.

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

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

Где вызывается хук

wp_network_admin_email_change_notification()
network_admin_email_change_email
wp-includes/ms-functions.php 2883
$email_change_email = apply_filters( 'network_admin_email_change_email', $email_change_email, $old_email, $new_email, $network_id );

Где используется хук в WordPress

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