#47605 closed feature request (duplicate)
Email sender name change with site title in wp-includes/pluggable.php
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 2.2 |
| Component: | Keywords: | has-patch | |
| Focuses: | Cc: |
Description
A variable $from_name has default WordPress name as sender on line 316 in file name pluggable.php exist in wp-include folder.
Where there is a line replacement with site name of WordPress website. The result will show in email with Site title of website in email of sender name.
Attachments (3)
Change History (14)
#2
@
7 years ago
Hello @audrasjb,
Thank you.
Thank you again for suggestion. I am aware about hook but it would be great to have default inbuilt function for sender name. For this purpose I am requesting to add in core functionality.
#3
in reply to:
↑ 1
@
7 years ago
- Keywords needs-refresh added
- Version set to 2.2
As @audrasjb said there is already filter available to change default $from_name . please remove an extra space from 45562.patch.patch patch.
Replying to audrasjb:
Also, looks like there is an extra space that should be removed in the patch provided :-)
#5
in reply to:
↑ 1
@
7 years ago
Hello @audrasjb,
I have added new patch file named as:45562.patch.2.patch . Please review it.
Replying to audrasjb:
Hello @viitorcloudvc and welcome to WordPress Trac,
Thanks for the ticket, I'm moving it to the
By the way, there is already a hook to filter the From Name parameter for all WP mails: https://developer.wordpress.org/reference/hooks/wp_mail_from_name/
Also, looks like there is an extra space that should be removed in the patch provided :-)
#6
@
7 years ago
@viitorcloudvc Welcome to trac!
Looks like you have removed extra space before variable, but due to WPCS, you need to fix below errors,
Expected 1 space after opening bracket;
Expected 1 space before closing bracket;
:)
#10
@
6 months ago
- Keywords needs-testing removed
- Resolution set to duplicate
- Status changed from new to closed
This is quite tricky. For example, what happens with multisite?
For example, on creation of a new user, it will send an email
By using get_bloginfo( 'name' ); it will take the main blog, but maybe you would rather not disclose the main blog name when doing such.
The right way to proceed here is programmatically with wp_mail_from_name as @audrasjb and @mukesh27 have suggested.
There are already some proposals regarding the Senders mail (and transitively, sender's name), like #60420. For this reason, I'm going to be closing this as a duplicate to focus effort for a resolution just in one ticket.
Hello @viitorcloudvc and welcome to WordPress Trac,
Thanks for the ticket, I'm moving it to the
Mailcomponent.By the way, there is already a hook to filter the From Name parameter for all WP mails: https://developer.wordpress.org/reference/hooks/wp_mail_from_name/
Also, looks like there is an extra space that should be removed in the patch provided :-)