In the following function, the $aFrom variable sets the "from" field to be an email address to which the recipient can reply. However, what if I want to add a "from" name. For example, my email address is johndoe@gmail.com, but when the person gets the email I want them to see that the email is from "John Doe". They should still be able to reply to johndoe@gmail.com though.
public static function SendMail_HTML($aFrom, $aTo, $aSubject, $aMessage) {
$theHeaders =
'MIME-Version: 1.0' . "\r\n" .
'Content-type: text/html; charset=UTF-8' . "\r\n" .
'From: ' . $aFrom . '' . "\r\n" .
'Reply-To: ' . $aFrom . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail($aTo, $aSubject, $aMessage, $theHeaders);
}