这是我的代码。我非常新,在这不到2周,我知道这里有一个语法错误,但它一直告诉我T_variable在第12行是意想不到的。它匹配“... input type =”text“name =”名字”值=‘名... \’信息,以便有人可以帮一下?菜鸟需要帮助!只是有点...?任何你能告诉我将非常感谢。意外的T_VARIABLE行12
<?
$correct = true;
if ($_GET["name"] == "")
$correct = false;
if (preg_match("/^[email protected]\w+\.\w{2,4}$/", $_GET["email"]))
$correct = false;
$to = "[email protected]";
$subject = "Application request";
$message = "A new request has come in!;\n\n"
$message .= $_GET["firstname"].;
$message .= $_GET["lastname"].;
$message .= $_GET["email"]."\n";
$message .= $_GET["phone"]."\n";
$message .= $_GET["dropdown"]."\n";
$message .= $_GET["address"]."\n";
$message .= $_GET["dropdown2"]."\n";
$message .= $_GET["textarea"]."\n";
(mail($to, $subject, $message);
?>
<body>
<? if ($correct): ?>
Thank you for applying. We will get back to you shortly.<br>
<? if else: ?>
Please complete the form.
</ end if ?>
</body>
我的意思不是使用SO劝阻,但请继续RTFM。 – Dan 2013-04-05 18:49:36