I have this form on localhost on my Mac. The port, username and password info are the same as what I use on my cellphone, and the host info is also the same with the exception of the "ssl://" part. Compliant with Yahoo's specs too.
As you can see, I have this set up to send mail to myself for testing purposes, and I'm not getting any email.
I am not getting any error messages. The form is submitting. Is it because there is something wrong with the code, or is it because it is not possible to do this via localhost for some reason?
<form action="sales_HE.php" method="post">
<?php
$to = 'me@yahoo.com';
$subject = 'the subject';
$message = 'hello';
$headers = 'From: me@yahoo.com' . "\r\n" .
'host: ssl://plus.smtp.mail.yahoo.com' . "\r\n" .
'port: 465' . "\r\n" .
'auth: true' . "\r\n" .
'username: me' . "\r\n" .
'password: mypwd' . "\r\n";
mail($to, $subject, $message, $headers);
?>
<input name="" type="submit" />
</form>
Thanks in advance for any help.