# Flash/PHP form working sparatically

**URL:** <https://forum.kirupa.com/t/flash-php-form-working-sparatically/229062>\
**Category:** programming\
**Created:** [June 13, 2007, 7:28pm UTC](https://forum.kirupa.com/t/flash-php-form-working-sparatically/229062 "2007-06-13T19:28:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Filmguy15](https://avatars.discourse-cdn.com/v4/letter/f/82dd89/32.png) [@Filmguy15](https://forum.kirupa.com/u/Filmguy15)\
**Post date:** [June 13, 2007, 7:28pm UTC](https://forum.kirupa.com/t/flash-php-form-working-sparatically/229062/1 "2007-06-13T19:28:55Z")

</div>

I have a flash website which has a contact for within it, which is tied to a php file sending it to a specified email address. The problem is that it seems to be working sparatically. Sometimes I will get the emails and sometimes I won’t. It almost seems as if I close the browser then I won’t get them, but if I leave it open then check my email, I do. But I’m not 100% on this… Here is the php code I’m using…

```php

<?php
$sendTo = "filmguy_15@hotmail.com";
$subject = "RFQ Form Request";
$headers = "From: " . $_POST["fname"];
$headers .= "<" . $_POST["email"] . ">
";
$headers .= "Reply-To: " . $_POST["email"] . "
";
$headers .= "Return-Path: " . $_POST["email"];
$company = $_POST["company"];
$fname = $_POST["fname"];
$lname = $_POST["lname"];
$address = $_POST["address"];
$city = $_POST["city"];
$state = $_POST["state"];
$zip = $_POST["zip"];
$phone = $_POST["phone"];
$email = $_POST["email"];
$how = $_POST["how"];
$price = $_POST["price"];
$eaq = $_POST["eaq"];
$comments = $_POST["comments"];

$body = "Company: $company
Name: $fname $lname
Address:
$address
$city, $state $zip
Phone: $phone
Email: $email
How they heard about us: $how
Target Price: $price
EAQ: $eaq
Additional Comments: $comments";

mail($sendTo, $subject, $body, $headers);
?>

```

And I have this action on my button…

```auto
on (release) {
form.loadVariables("rfq.php", "POST");
gotoAndPlay(2);
thanks.gotoAndPlay(2);
}

```

the gotoAndPlays are for the overlay that says “Thanks”

Any help would be appreciated…THANKS!

-Filmguy
