MyBB Community Forums

Full Version: How to use PHP mail to send emails
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey,

I cannot find a way to make it work. It doesn't send the emails, and the administrative email/the email stuff is a gmail account. (I got no SMTP servers/cannot find free ones).

Any ideas?
Try this test script: https://docs.mybb.com/1.8/faq/mail/

If this doesn't work, you'll need to ask your host.
(2021-09-23, 08:54 PM)Matt Wrote: [ -> ]Try this test script: https://docs.mybb.com/1.8/faq/mail/

If this doesn't work, you'll need to ask your host.

Hmm, alright. Do you know any free SMTP servers? It doesn't need to be much, no many mails will be send anyway.
We use php mail - have for over 8 years.  When we migrated hosts with our provider - had to chase them a bit - but got it working again.

At some point - may have to switch over to smtp mail - but haven't yet.  When we do, will likely leverage Omar's tutorial linked here.
(2021-09-24, 02:37 PM)Task Wrote: [ -> ]
(2021-09-23, 08:54 PM)Matt Wrote: [ -> ]Try this test script: https://docs.mybb.com/1.8/faq/mail/

If this doesn't work, you'll need to ask your host.

Hmm, alright. Do you know any free SMTP servers? It doesn't need to be much, no many mails will be send anyway.


Mailgun is free up to 1.25K emails/month. You have to put a card on file in case you go over though, but if your community is small, you shouldn't run over the 1.25K free tier. 

PHP Mail is usually fine enough for small communities if recipients are able to get emails, but some hosts are on various third party blacklists that label entire IP address ranges as spam, and some of them (UCEProtect comes to mind) go so far as to blacklist to the extent that Gmail won't receive emails at all. If this is happening, you'll either need to switch hosts or use SMTP mail of some sort. PHP mail is notoriously unreliable for this reason.