PHP mail() Function Is Not Working

Status
Not open for further replies.

barun353

New Member
Messages
7
Reaction score
0
Points
0
Dear Sir,

When I was trying to send mail by the PHP mail() function, it returned the boolean value FALSE and mail was not delivered. Please check it and fix it as soon as possible.

Thanking You!
 

descalzo

Grim Squeaker
Community Support
Messages
9,372
Reaction score
326
Points
83
The PHP function mail() is working fine on Boru and Chopin.
The usual problem on the servers is that it returns True and the mail is not sent.

Perhaps it is your code. Did it ever work on your x10hosting account? If so, when did it stop working? Could you supply the code you are using.
 

barun353

New Member
Messages
7
Reaction score
0
Points
0
Thanks but I'm currently under the server - Starka. I did not use PHP mail() function before. Now I am trying to send mail by PHP mail() function and it is returning the boolean value FALSE. The code I was using written below -
PHP:
<?php
if(mail("receiver@receiver.com", "Test Subject", "Test Body", "From: sender@sender.com"))
    echo "Mail Sent";
else
    echo "Mail Not Sent";
?>
receiver@receiver.com and sender@sender.com are replaced by real email ids.

I am getting the output - Mail Not Sent

I used PHP function function_exists() to check if mail() is exists or not, it returned the boolean value TRUE which means mail() is exists but not working.

Please check the issue and fix it.
 
Status
Not open for further replies.
Top