Must be in Actionscript 3 - A form that submit values to php then goes to frame 2

What i am making is a simple username/password form in Flash using Actionscript 3.

What i want to do is after the user enters username/password and hits submit, the form should submit to a url that will process the form variables and then return some values back to flash.

I want it so if everything goes ok that the flash movie will go to frame 2. On frame i want to output information and data about the user (like username, screen name, member photo, and email address.)

I’m sure this is possible but how do you get the form to submit to the script and then go to frame 2 ?

I’m able to pass variables back to the flash movie in frame 1, does the data retrieved from the database and outputted to the flash movie, does it remain there no matter what frame I go too?