I’m working with an email form in flash which is supposed to send data to a PHP form but it seems to freeze after the send button is pushed which leads me to believe that the PHP form isn’t being communicated with.
the “email.php” file is located in the same place as the flash file on the server.
this is the code on the “send” button. all of the input text fields and dynamic response field have variable names which are called in this code
on (release) {
if (!email.length || email.indexOf("@") == -1 || email.indexOf(".") == -1) {
results = "Please check your e-mail address.";
} else if (!comments.length) {
results = "Please enter your comments.";
} else if (!name.length) {
results = "Please enter your name.";
} else {
loadVariablesNum ("http://www.orcaproductions.com/email.php?name=NTD&email=tania.alexis@gmail.com", 0, "GET");
results = "Sending Data...";
}
}
one thing i’m wondering is if i should have a “_root” command before loadvariablesNum because this form does not exist on the main timeline…
the PHP code is as follows:
<?php
$TextVariable = '&results=';
$response = 'Data Sent. Thank You..';
echo $TextVariable;
echo $response;
$recipient .= "tania.alexis@gmail.com" ;
$subject = "Your Automail";
$message .= "Name: $name
Email: $email
Comments: $commentsn";
$headers .= "From: $name <$email>n";
mail($recipient, $subject, $message, $headers);
?>
when i use the form it just keeps saying “sending data…” in the response box.
I’ve tried so many different things and nothing seems to change it.
Thank you to anyone who may be able to help…i owe ya one.