hi every one!!
i am having problems with the mail() of php. In this,i would like to know how u can use "from header" ? for eg: im filling one form ,wich asks for UR email id and To mail id.
from this form, im retrieving the from email id , bt i cant seem to use the from email id in mail ().
i have tried " $from= $_POST['email'];
$to = $_POST['to_email'];
$body = "hi everyone";
$subject =" CHECK MAIL";
$headers = 'From: <register@tech.com>' . "\r\n" . 'Reply-To: register@tech.com' . "\r\n";
mail($to, $subject, $body, $headers);
But i would like to know how to use $from address in my mail function.
Please help me as soon as possible.
I hav tried replacing $headers =" FROM : $from ";
But it doesnt send the mail.....so i would like to know if there is any other option?plsss help
thanks in advance