MyBB Community Forums

Full Version: Office 365 & STARTTLS
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello, 

I am just in the process of setting up own MyBB board and everything has so far run smoothly, I just have an issue with trying to set up the Mail Notifications via SMTP. 

Could I just check and confirm if MyBB is able to support Office 365 using STARTTLS?  

I am using the following details: 

Hostname:  smtp.office365.com
Port:  587
Username:  Full E-Mail Address
Password:   Password
Encryption Mode:  TLS
Logging:  Everything
Mail Headers:  Yes

There are no entries in the System Mail Log itself but anytime a mail is attempted to be sent the end user gets an Internal SQL Error (please see attached).
The trouble seems to be with SQL, not with the SMTP.
Have you any plugin which can log mails into DB ? Which version of MyBB are you using ? and theme / plugins ?
Hi Crazycat, 

Just a new/out of the box install of My BB 1.8.24 with no addons etc. 

PHP Version 7.4.3
SQL Engine MySQLi 8.0.21
Have you activated the error logs ? Select "Warnings & Errors" in Home » Board Settings » Server and Optimization Options

Try to change the mailer log and test without logging (must work) and "Log emails without content". If this last one works, the trouble might be in the content of email, I'll have a look in MyBB sources to check if there's not a lack in escaping content.
Many thanks Crazycat. 

I had not enabled the logs - I shall give this a go now and report back any errors it captures. 

Many thanks.

Issue resolved (human error) - I had set a completely different E-Mail address in the 'Admin Email' field than what was being used within the SMTP Settings. 

Office 365 will not allow you to send from any other E-Mail Address to prevent spoofing.  

Many thanks for all your appreciated help and assistance Crazycat.