Change WordPress email from name

To change the e-mail from name and e-mail in WordPress you need the following 2 filters:

<?php

add_filter( 'wp_mail_from', 'new_mail_from' );
function new_mail_from( $email ) {
    $email = 'me@mywordpressite.com';
    return $email;
}
add_filter( 'wp_mail_from_name', 'new_mail_from_name' );
function new_mail_from_name( $name ) {
    $name = 'My Cool WordPress Site';
    return $name;
}
?>
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s