# Flash Email Form

**URL:** <https://forum.kirupa.com/t/flash-email-form/170771>\
**Category:** Uncategorized\
**Created:** [November 29, 2005, 2:06pm UTC](https://forum.kirupa.com/t/flash-email-form/170771 "2005-11-29T14:06:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![willdrury](https://avatars.discourse-cdn.com/v4/letter/w/5e9695/32.png) [@willdrury](https://forum.kirupa.com/u/willdrury)\
**Post date:** [November 29, 2005, 2:06pm UTC](https://forum.kirupa.com/t/flash-email-form/170771/1 "2005-11-29T14:06:35Z")

</div>

I have followed the tutorial for creating an email form in flash, however, when i click the send button nothing happens. The script I have on the button is…

on (release) {

if (!email.length || email.indexOf("@") == -1 || email.indexOf(".") == -1) {  
emailstatus = “PLEASE ENTER A VALID EMAIL ADDRESS”;  
}

else if (!name.length) {  
emailstatus = “PLEASE ENTER YOUR NAME”;  
}

else if (!message.length) {  
emailstatus = “PLEASE ENTER A MESSAGE”;  
}

else {  
form.loadVariables(“contactus.php”, “POST”);  
emailstatus = “SENDING…”;

}

}

The php code is…

\<?php  
$sendTo = "contactus@theliveotakeover.com";  
$subject = “Email from Site”;

$headers = "From: " . $\_POST[“name”];  
$headers .= “\<” . $\_POST[“email”] . "\>  
";  
$headers .= "Reply-To: " . $\_POST[“email”] . "  
";  
$headers .= "Return-Path: " . $\_POST[“email”];  
$message = $\_POST[“message”];

mail($sendTo, $subject, $message, $headers);  
?\>

Can anyone see why it isnt working?
