Can't send e-mails by mail()


Sorry for my disgusting English.

I send only 3-4 e-mails to my e-mail boxes from site.
But the e-mails didn’t reach.
There are shown 105 e-mails sended from my site in the statistics.
When e-mails quantity reached to 45 I have turned off “sendmail” option in my cpanel, but nothing changed.
Make me a favor stop sending process and also help me with code.

$subject = “=?utf-8?B?”.base64_encode($subject)."?=";
$headers = “MIME-Version: 1.0\r\nFrom: $from\r\nReply-to: $from\r\nContent-type: text/html; charset=utf-8\r\n”;
return mail($to, $subject, $message, $headers);

My site address is -


Please note that you are allowed to send only 50 e-mails per day.


Thank you for answering quickly!
I only sent 4 e-mails, but the statistic shows 105, and the number is rising every hour.


I created a mail script inside website’s root. I’ve sent an email, but it doesn’t receive as well.

Do you have many visitors on your site? What URL should people access in order to receive e-mails from your website?


I have no visitors but me.
I am jast debuging scripts.
How could your mail be received if the limit of 50 was already reached.
The e-mail is sending after registration on the site.
Here is URL of registration form -


I forgot to say that I had switched off sendmail option.
Should I turn it on?


Yes, of course… I actually missed that one. Now it’s obvious why the e-mails were not receiving :smile:


Now it is turned on.
Thank you for helping me!


I tried to create an account, but I receive no emails. I will try again tomorrow.

Please remove the user with email: from your database, so I can try register again later :slight_smile:


Done. It’s removed.
Good night!
Thanks again!


I have created another account, but yet I do not receive any emails. I am using an anonymous service, which does not have strict spam filters :confused:

Please change the PHP version to 5.6, and I’ll try again.


Excuse me for not coming yesterday to the forum.:pensive:
I still have statistics showing that 7-10 letters are sent from my site every hour.
And now I have used 235 out of 50 (470%).
Did you send a letter using your script?
That is, could you get a letter?
Maybe the problem is in my script?
Or maybe with a free account I can not send HTML letters?
The version of PHP has already changed from 5.2 to 5.6.


I have not a single idea.

Do you have anything added at cron jobs? (cPanel > Settings > Cron Jobs)


I’m thinking of writing one script that will clean out the “images/wallpapers/” folder.
And I want to add it to “cron jobs”.
But I have not done anything yet.
Come on, I’ll turn off Sendmail for 2 days. Let’s see what happens …


Come on, I’ll turn off Sendmail for 2 days. Let’s see what happens …

I think your script will keep trying sending emails forever, but you can give it a shot :wink: