• schulz

    (@schulz)


    By default when you send any notification from your blog (including many of the plugins as well) sender is “WordPress” and the sender e-mail address is [email protected].

    Why must we have to use a plugin or add filters to the functions.php file or edit the pluggable.php file to fix this? (according to the search results on this issue)

    Because most people won’t have an actual ‘[email protected]’ email address any out going email will be flagged as spam or not make it to the destination at all. Most people new to WP won’t even know this is a problem or they simply don’t know how to fix it themselves.

    Seems that this should be a simple fix for the developers? Why couldn’t they have this in the WP settings? Or at least be able to set these two attributes in the wp-config.php file? Or asked and set during the WP install?

Viewing 10 replies - 1 through 10 (of 10 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    It’s meant to be not a real address, like noreply. Not having the address exist doesn’t automagically get it flagged as spam, though.

    Thread Starter schulz

    (@schulz)

    I would have to disagree with Ipstenu statement.

    See: https://www.gettingemaildelivered.com/why-all-the-email-addresses-you-send-from-should-really-exist

    If WordPress developers are not going to ever fix this, then at least they could have it somewhere prominent in the documentation that creating a ‘[email protected]’ email account would be a good idea (however I’d rather they fix it).

    Jaaaarne

    (@jaaaarne)

    I have to agree with Schulz. I’ve recentrly discovered that new comments notifications from WordPress never reach my Gmail address. However, if I change user address to some other email service, the notifications come though fine. They are obviously getting rejected by Gmail for some reason. I have a feeling that this is somehow related. Gmail probably identifies them as fake, because they do not even reach the spam folder.

    Dion

    (@diondesigns)

    I actually think this is a bug. WordPress doesn’t set $auto to false when calling $phpmailer->setFrom() in the wp_mail() function. If $auto is true, PHPMailer will call its ::Sender() function, which sets the return-path header (“f” parameter) to the usually-invalid email address.

    An invalid return-path header is going to trigger a reject from Gmail, Outlook, and most ISP-based email providers. (Not setting the “f” parameter could result in the same problem. but in this case it’s the lesser of two evils.)

    There are several ways to fix this. The best is a rewrite of the (10-year-old) wp_mail() function, coupled with a new “Mail” option in dashboard Settings that sets how email is sent — and has support for SMTP. PHPMailer supports SMTP, WordPress is loading the SMTP support class, and it only takes five extra lines of code to send an email via SMTP.

    Heck, one could even parse the admin-supplied email address, and if its domain is the same as $_SERVER['SERVER_NAME'], default to the mail() function and set the return-path header to the supplied email address. Otherwise require SMTP credentials.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    There are already plugins and filters to do this

    https://www.wpbeginner.com/plugins/how-to-change-sender-name-in-outgoing-wordpress-email/ has some good help there.

    The reason I don’t feel it has to be a real address is that many of people who use WordPress sites don’t have multiple users nor a need to email anyone but themselves. For a site that has a lot of users, or open registration, obviously it’s different. But thanks why the plugins exist ??

    Thread Starter schulz

    (@schulz)

    Now we gone full circle…

    Re: “Why must we have to use a plugin or add filters to the functions.php file or edit the pluggable.php file to fix this”

    We should not have to do all that. Plugins add up fast and should only be used to enhance or add functionality, not fix short comings. Having to create filters or alter code can have adverse effects on the site performance/security if not outright break it due to a mistake, WordPress should not need ‘patching’ out of the box regardless what the plans are for the install.

    Even if the install is not for “multiple users nor a need to email anyone but themselves” the site admin still needs to be able to receive messages from their site. Again many people that are installing a basic minimal WordPress site are likely not going to be aware about this issue and assume that all is quiet at their site when it really not. Worse their domain/IP may get marked as a spam source because they are unaware that blocked messages are being sent out from their site.

    In my opinion, Schulz deserves a prize.
    And Ipstenu deserves…

    nothing?
    Nope.

    This issue is SO obvious, and SO old (since wordpress’ inception – before Ipstenu or Schulz were around). It should be fixed before any of that crap is being rolled out… rel=noopener… auto nofollow (100% harming every wordpress’ site’s SEO without the site owner even realizing!!)… still no URL to input in media library, instead that idiotic “housewives” customiiiizer… and on and on.

    Ah well, coding never suggested one has brain. Right? LOL

    It is an identification, every identification must have an option to be changed. Current site Title and site Description can be changed too, description after install, but still, you CAN change it…

    One must be able to change both – sender name and sender email.

    I agree with @schulz.

    @ipstenu let me rewrite this for you a bit:

    The reason I don’t feel it has to be a real title or description is that many of people who use WordPress sites don’t have anyone looking at it but themselves. For a site that has a lot of people looking at it, obviously it’s different. But thanks why the plugins exist

    – would you like to remove title & description too?

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Huh, I thought y’all were done bashing on me over that one.

    1) You can change the email and the username if you want. There are filters and plugins for this.

    2) A standard email ([email protected]) is easier to manage en masse and debug.

    3) Arguments like ‘would you like to remove title & description too?’ are pointless. Because I absolutely would remove them, via filters and hooks, if I wanted to.

    Which brings us back to item the first.

    You CAN do this.

    Back to the initial complaint:

    “Why must we have to use a plugin or add filters to the functions.php file or edit the pluggable.php file to fix this”

    Please never edit core files, but the answer to ‘Why do we use filters and plugins?’ is ‘Because everyone is different and everyone uses WP differently.’

    This post has outlived its usefulness, if people are headhunting just to be snarky, though, so I’m closing it. This doesn’t mean I’m for or against anything. I personally feel it’s better done via filters (and thus plugins) for the minority of people who want or need it.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Setting WP default email sender’ is closed to new replies.