Hi, don't know if this is the right place but I'll just give it a try...
I want to send an email with flash trough php, It sends an email, but doesn't include the message, name, email and so on...
PHP Code:
Actionscript:
the names of my textfields in flash are identical with the vars in the php...
It sends this to my email:
What am I doing wrong??
I want to send an email with flash trough php, It sends an email, but doesn't include the message, name, email and so on...
PHP Code:
| Code: |
| <?PHP
$to = "user@gmail.com"; $subject = "Flash Contact Form Submission"; $message = "Name: " . $theName; $message .= "\nEmail: " . $theEmail; $message .= "\n\nMessage: " . $theMessage; $headers = "From: $theEmail"; $headers .= "\nReply-To: $theEmail"; $sentOk = mail($to,$subject,$message,$headers); echo "sentOk=" . $sentOk; ?> |
Actionscript:
| Code: |
| var senderLoad:LoadVars = new LoadVars();
var receiveLoad:LoadVars = new LoadVars(); sender.onRelease = function() { senderLoad.theName = theName.text; senderLoad.theEmail = theEmail.text; senderLoad.theMessage = theMessage.text; senderLoad.sendAndLoad("http://flash.reignofterror.be/send.php",receiveLoad); } receiveLoad.onLoad = function() { if(this.sentOk) { theMessage.text = "OK" } else { theMessage.text = "NOT ok" } } |
the names of my textfields in flash are identical with the vars in the php...
It sends this to my email:
| Quote: |
|
Name: Email: Message: |
What am I doing wrong??
