hmmmm, i did this in xampp (i see you have that too e-giggle) in the php.ini. this is the INI's code:
[mail function]
; For Win32 only.
SMTP = mail.yahoo.com
smtp_port = 25
; For Win32 only.
sendmail_from = myemail@yahoo.com
; For Unix only. You may supply arguments as well (default: "sendmail -t -i").
;sendmail_path =
this is on a windows box so it doesn't matter that i put in the UNIX stuff.
secondly this is my mail.php:
<?php
$to = 'myemail@yahoo.com';
$subject = 'the subject';
$message = 'hello';
$headers = 'From: [email]webmaster@example.com[/email]' . "\r\n" .
'Reply-To: [email]webmaster@example.com[/email]' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
//ini_set("SMTP","smtp.yoursite.com");
mail($to, $subject, $message, $headers);
?>
and this is the error that i keep getting:
error wrote:
Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\Program Files\Developer\apachefriends\xampp\htdocs\member\mail.php on line 9