I have a simple form that passes its text fields to a PHP file that then adds them to a database. All of the text fields work but I do not know how to pass the info from a radio button to the database.
Because its just 2 radio buttons, I just manually added them to the stage from the components window. Then in my ActionScript 3 code I said:
naming the radio button groupName "testing".
Then in the rest of the code where I call the text fields I write
ActionScript Code:
function submitToPHP() {
var url:String = "submit_to_db.php";
var variables:URLVariables = new URLVariables();
variables.to_name = to_box.text;
variables.from_name = from_box.text;
variables.testing = testing;
The database is set up to accept the form field as a "varchar".
There is more code that makes all of this work but those are the pieces that involve the radio buttons. Hopefully this makes sense but if it would help for me to show all of my code or anyone has a tutorial on creating forms with check boxes and radio button that integrate into a database, I would appreciate it.