phpmailerHow do I disable STARTTLS in PHPMailer?
To disable STARTTLS in PHPMailer, you need to set SMTPSecure to false and SMTPAutoTLS to false in your mailer configuration.
Example code
$mail = new PHPMailer;
$mail->SMTPSecure = false;
$mail->SMTPAutoTLS = false;
These two settings will disable the STARTTLS encryption in PHPMailer.
Code explanation
SMTPSecure- This setting is used to set the encryption type of the connection. Setting it tofalsewill disable encryption.SMTPAutoTLS- This setting is used to enable or disable TLS encryption automatically. Setting it tofalsewill disable it.
Helpful links
More of Phpmailer
- How can I configure PHPMailer to work with GoDaddy?
- How can I use PHPMailer to send emails with a Yahoo account?
- How can I use PHPMailer with XAMPP on a localhost?
- How can I use PHPMailer without SMTP secure?
- How do I determine which version of PHPMailer I'm using?
- How can I send emails using PHPMailer without using SMTP?
- How can I use PHPMailer to send emails through Outlook?
- How do I configure the timeout settings for PHPMailer?
- How can I configure PHPMailer to support Polish characters?
- How do I configure PHPmailer to use Zoho SMTP?
See more codes...