note 112237 added to function.mail
| From: | Ron | Date: | Tue, 21 May 2013 08:35:09 +0000 |
| Subject: | note 112237 added to function.mail | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-194869@lists.php.net to get a copy of this message | ||
My mail function is not working:
<?php
$to = 'ronsebastian@gmail.com';
$subject = 'Test mail';
$message = 'Hi this is a test mail!';
$headers = 'From: webmaster@example.com' . "\r\n" .
'Reply-To: webmaster@example.com' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
if(mail($to, $subject, $message, $headers)){
print "SENT";
}else{
print "FAILED!";
}
?>
i get failed, what should i do, anything in the php.ini file?
----
Server IP: 69.147.83.199
Probable Submitter: 106.51.68.115
----
Manual Page -- http://php.net/manual/en/function.mail.php
Edit -- https://master.php.net/note/edit/112237
Del: integrated -- https://master.php.net/note/delete/112237/integrated
Del: useless -- https://master.php.net/note/delete/112237/useless
Del: bad code -- https://master.php.net/note/delete/112237/bad+code
Del: spam -- https://master.php.net/note/delete/112237/spam
Del: non-english -- https://master.php.net/note/delete/112237/non-english
Del: in docs -- https://master.php.net/note/delete/112237/in+docs
Del: other reasons-- https://master.php.net/note/delete/112237
Reject -- https://master.php.net/note/reject/112237
Search -- https://master.php.net/manage/user-notes.php