[wp-trac] [WordPress Trac] #64368: `Could not instantiate mail function` errors sending mail in 6.9
WordPress Trac
noreply at wordpress.org
Sat Dec 6 22:04:22 UTC 2025
#64368: `Could not instantiate mail function` errors sending mail in 6.9
--------------------------+-----------------------
Reporter: desrosj | Owner: SirLouen
Type: defect (bug) | Status: accepted
Priority: normal | Milestone: 6.9.1
Component: Mail | Version: 6.9
Severity: normal | Resolution:
Keywords: close | Focuses:
--------------------------+-----------------------
Comment (by siliconforks):
Replying to [comment:10 SirLouen]:
> Could not execute: /usr/sbin/sendmail -finfo at domain.name -t -i
It looks like he is setting `$phpmailer->Sendmail` to a complete command
line, with options? I think it's just supposed to be the path,
`/usr/sbin/sendmail`, no options. PHPMailer is supposed to set all the
options. (This is a bit different from the way `sendmail_path` works.)
> sendmail_path = /usr/sbin/sendmail -finfo@… -t -i
I'm confused about that one - the `-t` and the `-i` are fine, but the `-f`
is still not supposed to be there. Isn't that what caused his issue in
the first place?
> So with this in mind, the second one from @digitalblanket is because, if
the `Sender` is set up, then it will set the `From` to the `Sender` if
they are setting the `$phpmailer->From` instead of using the
`wp_mail_from` hook, that will eventually set the `From` and the `Sender`
at the same time with the same value. In his case, the patch coming to
6.9.1 will not solve anything.
Yes, in his case I think that it may require manual intervention by him to
fix the problem.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64368#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list