AS3 Contact Form Help!

For some reason the contact form that I have created using Flash CS5 and PHP is not working. When I press send, I do not receive an e-mail.

After someone fills out the form a “Thank You” messages appears with a Back button option.

I am not sure if something is wrong with my action script, php code, or my server. I have uploaded the files to my server and they are all in the same location but it is still not working.

Any help or advice would be much appreciated. Thank you!

PHP Code:

<?php 
$to = "hedrick34@yahoo.com"; 
$subject = ($_POST['senderName']); 
$message = ($_POST['senderMsg']); 
$message .= "

---------------------------
"; 
$message .= "E-mail Sent From: " . $_POST['senderName'] . " <" . $_POST['senderEmail'] . ">
"; 
$headers = "From: " . $_POST['senderName'] . " <" . $_POST['senderEmail'] . "><" . $_POST['senderCompany'] . "><" . $_POST['senderAddress'] . "><" . $_POST['senderTelephone'] . "><" . $_POST['senderMobile'] . "><" . $_POST['senderFax'] . ">
"; 
if(@mail($to, $subject, $message, $headers)) 
{ 
echo "answer=ok"; 
}  
else  
{ 
echo "answer=error"; 
} 
?>

Action Script 3 code on the first frame:

send_btn.addEventListener(MouseEvent.CLICK, sendMessage);
function sendMessage(e:MouseEvent):void{
    var my_vars:URLVariables = new URLVariables();
    my_vars.senderName = name_txt.text;
    my_vars.senderEmail = email_txt.text;
    my_vars.senderCompany = company_txt.text;
    my_vars.senderAddress = address_txt.text;
    my_vars.senderTelephone = telephone_txt.text;
    my_vars.senderMobile = mobile_txt.text;
    my_vars.senderFax = fax_txt.text;
    my_vars.senderMsg = message_txt.text;
    
    var my_url:URLRequest = new URLRequest("mail.php");
    my_url.method = URLRequestMethod.POST;
    my_url.data = my_vars;
    var my_loader:URLLoader = new URLLoader();
    my_loader.load(my_url);
    gotoAndStop(2);
}


clear_btn.addEventListener(MouseEvent.CLICK, reset);


function reset(e:MouseEvent):void {
name_txt.text = "";
email_txt.text = "";
company_txt.text = "";
address_txt.text = "";
telephone_txt.text = "";
mobile_txt.text = "";
fax_txt.text = "";
message_txt.text = "";
}

Action Script 3 code on the second frame (for the back button):

back_btn.addEventListener(MouseEvent.CLICK, back);


function back(e:MouseEvent):void {
    gotoAndStop(1);
    name_txt.text = "";
    email_txt.text = "";
    company_txt.text = "";
    address_txt.text = "";
    telephone_txt.text = "";
    mobile_txt.text = "";
    fax_txt.text = "";
    message_txt.text = "";
    
}