Well, when you use a form, the variables are passed onto the page that is called using the form, as in:
print "<form name=\"i_dunno\" action=\"http://www.domain.com/blah.php\" method=\"post\">";
print "<input type=\"text\" name=\"username\">";
print "<input type=\"password\" name=\"password\">";
print "<input type=\"submit\" value=\"Submit\">";
print "</form>";
Then when blah.php is called, you can simply use:
$username
Basically with the forms, whatever name you give the input, that will be your variable name on the page called.
So if on the form you enter "jack" for username, when you hit submit, oh blah.php, if you do:
print "$username";
it will print "jack"
I'm not sure exactly how passwords work with encoding and such, but I think you get the idea...I hope? 🙂