I should preface this by saying that I know practically *nothing* about Flash or ActionScript.
I'm placing a form input field into a Flash banner. I just need to know how to get the input from the banner into PHP for processing. I don't need to send anything back to Flash, I just need to get the information into php.
I'm using the components that come packaged with flash, namely, the textbox and the button.
The textbox instance name is 'email'
The button instance name is 'join'
The php file I want to post the information to is called 'j.php'
I tried to add the following to the first frame of the layer that the textbox appears in, but it didn't work at all. I press the button and nothing happens.
join.onRelease = function ()
{
var data_to_send:LoadVars = new LoadVars();
data_to_send.email = _root.email.text;
data_sto_send.sendAndLoad("j.php",data_to_send,"POST");
}
I also tried the variant:
join.onRelease = function ()
{
var data_to_send:LoadVars = new LoadVars();
data_to_send.email = _root.email.text;
data_sto_send.sendAndLoad("}
But that didn't work either.
I know that the PHP code works fine because, once upon a time, the input text box was just good, old-fashioned html... Can someone help me out here?
I'm placing a form input field into a Flash banner. I just need to know how to get the input from the banner into PHP for processing. I don't need to send anything back to Flash, I just need to get the information into php.
I'm using the components that come packaged with flash, namely, the textbox and the button.
The textbox instance name is 'email'
The button instance name is 'join'
The php file I want to post the information to is called 'j.php'
I tried to add the following to the first frame of the layer that the textbox appears in, but it didn't work at all. I press the button and nothing happens.
join.onRelease = function ()
{
var data_to_send:LoadVars = new LoadVars();
data_to_send.email = _root.email.text;
data_sto_send.sendAndLoad("j.php",data_to_send,"POST");
}
I also tried the variant:
join.onRelease = function ()
{
var data_to_send:LoadVars = new LoadVars();
data_to_send.email = _root.email.text;
data_sto_send.sendAndLoad("}
But that didn't work either.
I know that the PHP code works fine because, once upon a time, the input text box was just good, old-fashioned html... Can someone help me out here?