Skip to:
Content
Pages
Categories
Search
Top
Bottom

Remove noreply email from notification emails


  • avaiya
    Participant

    @avaiya

    Wordpress Version:4.9.2
    bbPress Version: 2.5.14
    Site: http://www.avaiya.com

    I have a couple of questions related to the default emails that get sent when people post to forums, follow topics, etc.

    1. These emails show up as being sent from our admin email address, with the name Avaiya Media. I’d like to edit the name and the email address sending the emails. Do you know how I can do that?

    2. These emails send a notification to the person who subscribed to that forum post, but they also
    automatically send an email to noreply@avaiya.com. This is bouncing. How can I remove this email address when these emails are sent?

    Thanks!

Viewing 10 replies - 1 through 10 (of 10 total)
  • If you do not want to use a plugin, check out this snippets (that you could add into your functions.php):

    add_filter( 'wp_mail_from_name', 'email_sent_from_name' );
    function email_sent_from_name( $name )
    {
        return 'SITE NAME';
    }
    add_filter( 'wp_mail_from', 'email_sent_from' );
    function email_sent_from( $email )
    {
        return 'email@example.com';
    }

    Or for more granular tasks, consider even:

    add_filter('bbp_get_do_not_reply_address','my_bbp_no_reply_email');
    function no_reply_email(){
        $email = 'noreply@yourdomain.com'; // any email you want
        return $email;
    }
    
    add_filter('bbp_subscription_to_email','my_bbp_subscription_to_email');
    function my_bbp_subscription_to_email(){
        $email = 'noreply@yourdomain.com'; // any email you want
        return $email;
    }

    Reto Fischer
    Participant

    @reto-fischer

    And where is these functions.php?

    Best Regards Reto


    Robin W
    Moderator

    @robin-w


    Michael
    Participant

    @michael42

    Hi,

    I have the same question as avaiya how to remove – not to change – the noreply-address from the list of notified recipients if someone writes a post as this notification is useless.

    Thanks
    Michael


    Robin W
    Moderator

    @robin-w

    bbpress sends the notification as a single email, with the noreply address as the to/from an the recipients are then bcc’d in.

    So you can’t simply remove it.

    you can amend how bbpress sends using this plugin

    AsynCRONous bbPress Subscriptions


    Michael
    Participant

    @michael42

    Thanks, now I understand the issue completely.


    Robin W
    Moderator

    @robin-w

    great – glad you are fixed


    linguabuddy
    Participant

    @linguabuddy

    Looks like something may have changed as this code is now producing a fatal error.

    I used the second snippet to edit the reply emails but while the email send has been successfully modified (and is no longer bouncing), the user now gets a white screen…

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘my_bbp_no_reply_email’ not found or invalid function name in /home/customer/www/[domain]/public_html/wp-includes/class-wp-hook.php on line 287

    Has something been updated in the codex?


    Robin W
    Moderator

    @robin-w

    the code is valid – I suspect you have a copy/paste issue – sometimes a ‘ becomes corrupted,

    Can you post exactly what you have in your file

Viewing 10 replies - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.
Skip to toolbar