Link to home
Start Free TrialLog in
Avatar of Jazzy 1012
Jazzy 1012

asked on

How do I change the from header when sending a mail

User generated image
As you can see it is from Apache, How can I make it from "Customer Support".
This is my email code:
if(isset($_POST['submit']))
{

$check = mysqli_query($conn, "select * from users where email = '$email' ");
$row = mysqli_fetch_array($check);
$from= "Customer Support";
$message ="Please click here to create a new password http://home;
$subject = 'Change password';
$body = "E-Mail: $email\n Message:\n $message";

if($row)
{
	
    $res = mail ($email, $subject, $body,$from);
    header("Location: index.php/?a=1");
   //echo "Please check your email";
}

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Thomas Wheeler
Thomas Wheeler

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial