Hi all. I have been working on a action script and finally got it working. I am totally lost of how to write my PHP email codes for when the person press submit all the information they fill in is sent to me via email could someone help me please. I found tons of example off the internet to write a basic one but nothing close to what I have. Or better said none with check boxes buttons. Could someone please help me. Below is my action script code I use. The cb is for checkbox and radio buttons says radio and the other informationis normal input text box. This is working pretty good. I have problem with the check box but that I can work on later to figure out. My main concern is how can I code this action script to work in a PHP form..please help.
import fl.controls.*;
import fl.controls.RadioButtonGroup;
//This sets a group name for the radio button instances.
var myradioGroup:RadioButtonGroup = new RadioButtonGroup("RadioButtonGroup");
//This assigns the radio button instances to the radio group.
cRadio1.group = myradioGroup;
cRadio2.group = myradioGroup;
submit_btn.addEventListener(MouseEvent.CLICK, submitFunc);
var radBtns = [cRadio1,cRadio2];
var errorsNum = 0;
function submitFunc(e:MouseEvent)
{
var finalData = "";
var errorFlag = "Followings errors were found.\n";
if (name_txt.text == "")
{
errorsNum++;
errorFlag += errorsNum+". Enter ur name.\n";
}
if (email_txt.text == "")
{
errorsNum++;
errorFlag += errorsNum+". Enter ur email.\n";
}
if (mobile.text == "")
{
errorsNum++;
errorFlag += errorsNum+". Enter ur phone number.\n";
}
if (!myradioGroup.selection)
{
errorsNum++;
errorFlag += errorsNum+". Select ur gender.\n";
}
if (age.selectedIndex < 0)
{
errorsNum++;
errorFlag += errorsNum+". Select any of the course.\n";
}
if (!orangecb.selected)
{
errorsNum++;
errorFlag += errorsNum+". Please check one";
}
if (!orangelcb.selected)
{
errorsNum++;
errorFlag += errorsNum+". Please check one";
}
if (message_txt.text == "")
{
errorsNum++;
errorFlag += errorsNum+". Enter ur message.\n";
}
if (errorsNum > 0)
{
mytxt.text = errorFlag;
errorFlag = "";
errorsNum = 0;
return false;
}
else
{
finalData += "Thank you "+name_txt.text+" for contacting me! I will call you at "+mobile.text+", "+"else I can mail you also at "+email_txt.text+" in "+applecb.selected+"response "+orangecb.selected+" of your message "+message_txt.text+"\n\n Your other information is, you're a "+myradioGroup.selection.value+" and is between "+age.value+"\nThanks";
mytxt.text = finalData;
}
}