letxobnav, thanks very much for replying. I made your suggested changes, unfortunately they didn't work here. Insofar as I understand the OC source and sendmail, there isn't any reason that simple edit shouldn't have worked.
Inside php.ini, I set the sendmail_from variable to be our "from" address. It showed correctly in phpinfo() but still wasn't used to send the email.
So, as a fix and a sin against OO programming, I edited `system/library/mail.php` as such:
Code: Select all
public function setFrom($from) {
# $this->from = $from;
$this->from = 'noreply@<domain>.tld';
}
And now the emails send with the correct address and are not interned as "spam" due to failing domain authentication. I realise this has damned my soul (pray forgive me gracious devs), but it is unfortunately the only way I could get this to work.
However, this server has been throwing some other frustrating quirks... quirks that didn't appear when I ran OC from my original test server and so I don't think should be blamed on OC. I wouldn't be surprised if this issue is part of another problem server-end.
EDIT: I'm guessing my "fix" might clash with the "Contact Us" form, if we have the user's email as the "From" value. A saner idea might be to set the default value to our noreply in the constructor, then remove where setFrom() is called in the rest of the code when we want the default email.
paulfeakins wrote: ↑Fri Jun 19, 2020 6:09 pm
Noreply email addresses really annoy me.
You should consider setting up and using an actual email address at the website domain, getting email from a gmail address or similar looks very unprofessional.
I agree personally. However, given the current size of this website and client, it suits their current workflow to have it this way.
We'll have contact events and any notification emails from OC go to the client's personal email address.
Any notification to the customer will be sent from the noreply. That is more to do with avoiding the auth failures, since the emails are sent from the same server as the website. Thereby they won't appear as from the personal email address. We also expect clients to use the contact form or telephone number for queries.