Sending some data to PHP

I need some tips on how to send out some data to a PHP file. I have a project set up already where you vote for some options and that sends, but now I need to add some input text fields for people to enter some personal information. What I have right now are two fields with the vars of “name” & “email”

And here’s the code that is sending out the information to the PHP file:

submit.onRelease = function():Void

{
    sendVars();
    _root.gotoAndStop(2);
}

myLv.onLoad = function():Void
{
trace("data sent");
}
function sendVars():Void
{
    var len:Number = resultArray.length;
    for (i=1;i<len;i++)
    {
        myLv["var"+i]=resultArray*;
    }
    myLv.sendAndLoad("myphp.php",myLv,"POST");
}

I’ve tried a couple of different ways but so far all of them failed, they included creating another function like the “sendVars” function to send with the submit button and I also tried placing some code into the “sendVars” function relating to the “name” & “email” vars.

If anyone could provide some help on how to do this I would greatly appreciate it. Thank you so much!