如果输入的电子邮件与[email protected]匹配,您是否知道为什么此表单上的[输入电子邮件]字段只能到达[email protected]?PHP电子邮件表格将不会以不同的输入电子邮件地址提交
如果我输入的电子邮件地址不是$ to =中列出的电子邮件地址,那么电子邮件将不会发送。
$fieldname = 'images';
if ($_POST){
// we'll begin by assigning the To address and message subject
$to="[email protected]";
$subject="Registration";
$from = "<".stripslashes($_POST['email']).">";
// generate a random string to be used as the boundary marker
$mime_boundary="==Multipart_Boundary_x".md5(mt_rand())."x";
// now we'll build the message headers
$headers = "From: $from\r\n" .
"MIME-Version: 1.0\r\n" .
"Content-Type: multipart/mixed;\r\n" .
" boundary=\"{$mime_boundary}\"\n";
这是Pastebin。
它可能发送,但被标记为垃圾邮件 –
我与托管服务提供商合作并创建了电子邮件地址的子域,他们测试了它,并且工作正常。此外,没有邮件在垃圾邮件中。 – bunnycode
您可能想要传递完整的代码,包括PHP发送电子邮件的位置。 – pivemi