Problem with PHP email script
Thank you very much for your advice. I noticed that you are dealing with PHP as well. Can you find something wrong with this at a quick glance?
<?php
$name = $HTTP_POST_VARS['Name'];
$email = $HTTP_POST_VARS['Email'];
$message = $HTTP_POST_VARS['Message'];
$message = stripslashes($message);
$sendTo = "email address to be filled";
$subject = "Message from Contact Form";
$msg_body = "Name: $name\n";
$msg_body .= "E-Mail: $email\n";
$msg_body .= "Phone: $phone\n";
$msg_body .= "Street: $street\n";
$msg_body .= "City: $city\n";
$msg_body .= "Country: $country\n";
$msg_body .= "Company: $company\n";
$msg_body .= "Business: $business\n";
$msg_body .= "Position: $position\n";
$msg_body .= "Project: $project\n";
$msg_body .= "Houses: $houses\n";
$msg_body .= "Land: $land\n";
$msg_body .= "Port: $port\n";
$msg_body .= "Message.textArea: $message.textarea\n";
$header_info = "From: ".$name." <".$email.">";
mail($sendTo, $subject, $msg_body, $header_info);
?>
And the "Submit" button script is:
on (release){
Name = userName.text;
Email = userEmail.text;
Phone = userPhone.text;
Street = userStreet.text;
City = userCity.text;
Country = userCountry.text;
Company = userCompany.text;
Business = userBusiness.text;
Position = userPosition.text;
Project = userProject.text;
Houses = userHouses.text;
Land = userLand.text;
Port = userPort.text;
Message = userMessage.textArea.text;
loadVariables("contact.php",'POST');
}
All the fields are set as target in the actual form page and the names are userXxxxx.
Anyhow this combination does not work and I wonder if it will send any info that the message has been received.
Thanks
