Autoresponders的邮箱头显示名称而非邮箱地址,可以使用以下代码示例:
$headers = "From: Your Name \r\n";
$headers .= "Reply-To: Your Name \r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n";
$subject = "Autoresponder message";
$message = "Hello, this is an autoresponder message.";
mail("recipient@example.com",$subject,$message,$headers);
其中,"From"和"Reply-To"字段中的"name"应该是您想要显示的名称,"youremail@example.com"是您的邮箱地址。这个名称和邮箱地址可以根据您的需求进行修改。