通过邮件功能php发送电子邮件中的未知发件人

Hi I am using the the mail function in php to send emails but the emails in the inbox of the receiver show the name as "unknown sender" in gmail and going in spam in yahoo, here is the code for the function.

function send_email1($from, $fromaddress, $to, $sub, $mes)
{
  $headers = "MIME-Version: 1.0
";  
  $headers .= "Content-type: text/plain; charset=utf-8
";  
  $headers .= "To: ".$to." <".$to.">
";  
  $headers .= "From: ".$from." <".$from.">
";  
  $headers .= "Reply-To: ".$from." <".$from.">
";  
  $headers .= "Return-Path: ".$from." <".$from.">
";  

   mail($to, $sub, $mes, $headers);   
   return mail($to, $sub, $mes, $headers); ;
}

I have solved the problem. The code has now become as under:

function send_email1($from, $fromaddress, $to, $sub, $mes)
{
  $headers = "MIME-Version: 1.0
";  
  $headers .= "Content-type: text/plain; charset=utf-8
";  
  $headers .= "To: ".$to." <".$to.">
";  
  $headers .= "From: ".$from." <".$from.">
";  
  $headers .= "Reply-To: ".$from." <".$from.">
";  
  $headers .= "Return-Path: ".$from." <".$from.">
";  
  $headers .= "
";

   mail($to, $sub, $mes, $headers);   
   return mail($to, $sub, $mes, $headers); ;
}

I have just added the line

$headers .= "
";

and the email is not longer without the sender's name.