我正在使用以下代码发送确认邮件,但我不知道为什么邮件中的 url 参数被删除并且在邮件中我得到的 url 像http://example.com/confirm.php?user_id=
参数值 (1) 被删除
$headers = "From: admin@example.com \n";
$headers .= "X-Mailer: PHP/SimpleModalContactForm";
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-type: text/html; charset=utf-8\n";
$headers .= "Content-Transfer-Encoding: quoted-printable\n";
$subject = "Confirm Your Registration Example.com";
$subject = mb_encode_mimeheader($subject, "UTF-8", "B", "\n");
$to="abc@demo.com";
$body="<table> <tr> <td> Hello </td> </tr>";
$body.="<tr> <td> Please confirm your registration by clicking following link <td> </tr>";
$body.="<tr> <td> http://example.com/confirm.php?user_id=1</td> </tr>";
$body.="</table>";
@mail($to, $subject, $body, $headers) or die("Unfortunately, a server issue prevented delivery of your message.");