WC_Email::get_from_namepublicWC 1.0

Get the from name for outgoing emails.

Method of the class: WC_Email{}

Hooks from the method

Returns

String.

Usage

$WC_Email = new WC_Email();
$WC_Email->get_from_name( $from_name );
$from_name(string)
Default wp_mail() name associated with the "from" email address.
Default: ''

WC_Email::get_from_name() code WC 10.7.0

public function get_from_name( $from_name = '' ) {
	$default = get_bloginfo( 'name', 'display' );
	/**
	 * Filters the "from" name for outgoing emails.
	 *
	 * @since 2.1.0
	 *
	 * @param string|mixed $from_name        The from name.
	 * @param WC_Email     $email            Email object.
	 * @param string       $default_from_name Default from name.
	 */
	$from_name = apply_filters( 'woocommerce_email_from_name', get_option( 'woocommerce_email_from_name', $default ), $this, $from_name );
	return wp_specialchars_decode( esc_html( $from_name ), ENT_QUOTES );
}