loadVariables and mail function with php

Hi all,

I’m trying to send email from Flash. The email form is in a movie loaded with loadMovie. When I call the email.php page, it seems to take forever to do its thing and then nothing happens.

I based my script on the flash email form here in the Kirupa Tutorials and I’ve tried every way of giving the path to my variables - that is, the path to the text fields in the form via _root and _parent. I’ve tried appending variables the the loadVariables url and just tried posting them. I can’t even get any results when I use the print function in the php script. Here is my php script:


$name = $HTTP_POST_VARS['name_txt'];
$email = $HTTP_POST_VARS['email1_txt'];
$interest = $HTTP_POST_VARS['interest'];
$message = $HTTP_POST_VARS['message_txt'];
$recipient = "[email protected]";
$subject = "Enquiry about ".$interest." from the ITL Website";

$extras = "From: ".$name;
$extras .= "< ".$email." >
$extras .= "Reply-To: ".$email;

mail($recipient, $subject, $message, $extras);


It seems like my variables aren’t reaching the form, but I’m also concerned hat is is taking forever for any data to be returned to the flash movie (I’ve got an on(data) event on the form).

Thanks for your time.

Flash sometimes has problems with POST. The way I got it to work recently is by using sendAndLoad(url.php, loadVarsObjectToReceiveVars, “POST”)

Also, you may have to declare header info like this also:

$extras .= “MIME-Version: 1.0
$extras .= “Content-type: text/html; charset=iso-8859-1

Show us your flash code too, it maybe a problem there.