PHP Send Mail复制主体

| 我有这个脚本,该脚本向用户发送电子邮件以激活我的网站上的帐户,它的工作正常,我唯一的问题是它两次发送了邮件正文,有人可以看到并解释原因吗?
$toemail = $_POST[\'produgg_email\'];
// Send activation email 
$to = $toemail;
$subject = \"Website Activation\";
$headers = \"From: support@website\\r\\n\" .
$body = \"To activate your website.co.uk please click <a href=\'http://www.website.co.uk/activateuser.php?email=$toemail\'>here</a>\";

if (mail($to, $subject, $body, $headers)) {
  echo(\"<p>Message successfully sent!</p>\");
 } else {
  echo(\"<p>Message delivery failed...</p>\");
 }
    
已邀请:
        您粘贴了代码吗?如果是这样,则您有一个点而不是一个;在第5行...     

要回复问题请先登录注册