I am trying to use PHP's mail() function to send a test mail.
$to = "****@gourab.me";
$sub = "Php Mail";
$msg = "Test Message From PHP";
mail($to, $sub, $msg, "From: **********@gmail.com");
When I try to debug it through step
in phpdbg
, it shows the message:
[PHP Warning: mail(): " sendmail_from" not set in php.ini or custom "From:" header
missing in C:/xampp/htdocs/tinyProj/mail.php on line 4]
I cannot understand why?