would anyone know if it is possible to run phpmailer with STARTTLS encryption?
The story: an online order form that sends the output to both the site visitor and site owner. The goal is that the visitor receives an email from [email protected], while the site owner receives an email from [email protected] (the address that the visitor has filled i the online form).
I have the phpmailer running fine with my Gmail account, using TLS on port 587. I would, however, like to use mailbox provided along with the hosting (so that the from/replyTo looks professional, no freemail). Unfortunately, the hosting provider does not provide TLS - in their knowledgebase they only mention STARTTLS. I tried all combinations of SSL, TLS and STARTTLS for encryption and 465 and 587 for ports with no success.
Would anyone know if STARTTLS is somehow achievable, please?
My plan B would was to use the Gmail SMTP credentials and then tinker with addReplyTo, setFrom and addAddress in the phpmailer SMTP settings. I tried but if I use...
$mail->addReplyTo($_POST['customeremail'], $_POST['customername']);
...the from email address the site owner receives is that of my Google email - I understand this may be some Google email spoofing protection, which just doesn`t allow the SMTP to send an email with the From address taken from the form. - please see the attached ![Thunderbird screen( image: imgur.com/a/1f6vY).
Can this be possibly overridden?
I mean, with that plan B solution, I can grant Google access to send emails on behalf of [email protected]
, that`s all fine, it will then mimick the professional domain address. But I cannot do the same for the visitor address (taken from the form), that makes sense, right?
Thanks a bunch in advance...