Hi all, i want to send mail through php coding.but error displays. i am working in windows environment. please help..
PHP Coding:
<?php
$to = "anandh@yahoo.c om";
$subject = "Example";
$txt = "Test a Mail Function!";
$headers = "From: karthick@rediff mail.com";
mail($to,$subje ct,$txt,$header s);
?>
Error is:
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\xampp\htd ocs\textexample \mailfn.php on line 8
hoew to rectify this. please tell in detail...
PHP Coding:
<?php
$to = "anandh@yahoo.c om";
$subject = "Example";
$txt = "Test a Mail Function!";
$headers = "From: karthick@rediff mail.com";
mail($to,$subje ct,$txt,$header s);
?>
Error is:
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\xampp\htd ocs\textexample \mailfn.php on line 8
hoew to rectify this. please tell in detail...
Comment