Simple Form is driving me bonkers
I Just have 3 input fields. Right now I can’t even get these field to post to my e-mail address. But eventually I would like to have the input fields clear itself. And prior to typing in the email address, i would like that field to to have the words “e-mail address here”.
here is where I @
This is my sendmail.php
[COLOR=darkred]<?php
$destination="blug@charter.net";
$nowDay=date(“d.m.Y”);
$nowTime=date(“H:i:s”);
$email=$_POST[‘theEmail’];
$days=$_POST[‘theDays’];
$scores=$_POST[‘theScores’];
$FormContent="Message date = $nowDay at $nowTime
from: $email
Play on: $days
Score: $scores
";
if(mail($destination,"$subject[NoZeroStroke]",$FormContent,“From:$email”))
{
echo ‘response=Thanks for your e-mail’;
} else {
echo ‘response=failed’;
}
?>[/COLOR]
Here is my actionscript
[COLOR=darkred]
submit_btn.addEventListener(MouseEvent.CLICK, sendForm);
var loader:URLLoader = new URLLoader();
var req:URLRequest = new URLRequest(“sendmail.php”);
var variables:URLVariables;
variables.dataFormat = URLLoaderDataFormat.VARIABLES;
req.method = URLRequestMethod.POST;
email_txt.text=“E-mail Address here”
function sendForm(event:MouseEvent):void {
variables.theDays = days_txt;
variables.theScores = scores_txt;
variables.theEmail = email_txt;
req.data = variables;
loader.load(req);
days_txt.text="";
scores_txt.text="";
email_txt.text="";
}[/COLOR]
After noting most of the search examples this what I’ve lastried to no avail. Please Help.