hello,
I have written a basic script for the mail functionality. I am trying to run this script through WAMP server.
<?php
phpinfo();
$to = "[email protected]";
$subject = "Test mail";
$message = "Hello! This is a simple email message.";
$from = "[email protected]";
$headers = "From: $from";
$res= mail($to,$subject,$message,$headers);
echo " $res Mail Sent.";
?>
I have set the SMTP, sendmail_from in the php.ini file . It gives me the following error
Warning: mail() [function.mail]: Failed to connect to mailserver at "mucse409.eu.xyz.com" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\email.php on line 9 Mail Sent.
I am able to ping the SMTP address from my machine. Please guide me.