# Mail form doesn't work (ActionScript 2.0 and PHP)

**URL:** <https://forum.kirupa.com/t/mail-form-doesnt-work-actionscript-2-0-and-php/281524>\
**Category:** Uncategorized\
**Created:** [February 10, 2009, 9:44am UTC](https://forum.kirupa.com/t/mail-form-doesnt-work-actionscript-2-0-and-php/281524 "2009-02-10T09:44:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![BlindCarrot](https://avatars.discourse-cdn.com/v4/letter/b/ee59a6/32.png) [@BlindCarrot](https://forum.kirupa.com/u/BlindCarrot)\
**Post date:** [February 10, 2009, 9:44am UTC](https://forum.kirupa.com/t/mail-form-doesnt-work-actionscript-2-0-and-php/281524/1 "2009-02-10T09:44:17Z")

</div>

I’m trying to set up an e-mail form in flash, supported by PHP. However, it doesn’t work ^^"

the code used in the send button in the flash file:

[COLOR=#000084]on[/COLOR] (release) {  
[COLOR=#000084]if[/COLOR] (strName [COLOR=#000084]eq[/COLOR] “” [COLOR=#000084]or[/COLOR] strMessage [COLOR=#000084]eq[/COLOR] “” [COLOR=#000084]or[/COLOR] strAdress [COLOR=#000084]eq[/COLOR] “”) {  
[COLOR=#000084]stop/COLOR;  
} [COLOR=#000084]else[/COLOR] {  
loadVariablesNum(“mail.php”, 0, “POST”);  
strName = “”;  
strAdress = “”;  
strMessage = “Your mail has been [COLOR=#000084]send[/COLOR]. Thank you”;  
}  
}

mail.php contains the following code

```php

 <?php 

$to = "blindcarrot@live.nl"; 
$subject = "comment from" . $strName; 
$bericht = $strMessage ."
  
"  
$bericht = $strName ; 
$header = "From: " . $strName . " <" . $strAdress . ">
"; 
$header = "Reply-To: " . $strName . " <" . $strAdress . ">
"; 
$header = "X-Priority: 1"; 
mail ($to, $subject, $bericht, $header); 

$to2 = $strAdress; 
$subject2 = "Thanks for your mail"; 
$bericht2 = "thanks for your mail. You send the following: 
 
" 
$bericht2 = $strMessage ."
  
" 
$bericht2 = "We will take a look at your mail as soon as possible. 
 
 
" 
$bericht2 = "Blind Carrot keeps your strName and E-mail private and does not send spam. 
"  
$bericht2 = "This is a one time E-mail" ; 
$header2 = "From: the Blind Carrot Team" . " <BlindCarrot@noreply.com>
"; 
$header2 = "Reply-To: No Replies" . " <BlindCarrot@noreply.com>
"; 
$header2 = "X-Priority: 1"; 
mail ($to2, $subject2, $bericht2, $header2); 

?>  

```

it should send the message to our adress, along with an thank you message to the sender.

I double-checked all variable names. The site is hosted on [webs.com](http://webs.com)

I’m not very used to PHP, so I’m unable to figure out what is the problem…

Thanks in Advance =D
