mailsend = mail("myemail@gmail.com", "this is the email subjct"
, "this is the email body", "From: renault@cupon0km.com'r'n" . "X-Mailer: php");
print("$mailsend");
我正在使用 PHP 发送电子邮件,但我如何将以下变量添加到该电子邮件正文中?(这些值来自 POST 的先前值(
$_POST['CustomFields_17_5'];
$_POST['CustomFields_12_5'];
$_POST['email'] ;
$_POST['CustomFields_16_5'];
编辑:格式不是必需的
试试这个:
$body="this is the email body and these are my variables: ".$_POST['CustomFields_17_5']
." and ".$_POST['CustomFields_12_5'];." etc.";
mailsend = mail("myemail@gmail.com", "this is the email subjct"
, $body, "From: renault@cupon0km.com'r'n" . "X-Mailer: php");
print("$mailsend");