# Login Using Flash MX, PHP, and MySQL

**URL:** <https://forum.kirupa.com/t/login-using-flash-mx-php-and-mysql/148707>\
**Category:** Uncategorized\
**Created:** [May 22, 2005, 8:59pm UTC](https://forum.kirupa.com/t/login-using-flash-mx-php-and-mysql/148707 "2005-05-22T20:59:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![vegeto](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/vegeto/32/1301_2.png) [@vegeto](https://forum.kirupa.com/u/vegeto)\
**Post date:** [May 22, 2005, 8:59pm UTC](https://forum.kirupa.com/t/login-using-flash-mx-php-and-mysql/148707/1 "2005-05-22T20:59:12Z")

</div>

i did this tutorial :[http://www.kirupa.com/developer/actionscript/authentication.htm](http://www.kirupa.com/developer/actionscript/authentication.htm)

i made a db and made a a pass and username but i cant get it to login it keeps saying :Begin Login Process - Wait…

but it doesent go further

this is the code of the newlogin.php:

\<html\>  
\<head\>  
\<meta http-equiv=“Content-Type” content=“text/html; charset=iso-8859-1”\>  
\<title\>Untitled Document\</title\>  
\</head\>  
\<body\>  
\<?  
//this pulls the variables from the flash movie when the user  
//hits submit. Use this when your global variables are off.  
//I don’t know how to toggle global variables, so I just put  
//it in all the time 😉  
$user=$\_POST[‘user’];  
$pass=$\_POST[‘pass’];  
//connect to database  
if ($user && $pass){  
mysql\_pconnect(“localhost”,“root”,"") or die (“didn’t connect to mysql”);  
mysql\_select\_db(“login”) or die (“no database”);  
//make query  
$query = “SELECT \* FROM yourtable WHERE username = ‘$user’ AND userpassword = ‘$pass’”;  
$result = mysql\_query( $query ) or die (“didn’t query”);  
//see if there’s an EXACT match  
$num = mysql\_num\_rows( $result );  
if ($num == 1){  
print “status=You’re in&checklog=1”;  
} else {  
print “status=Sorry, but your user name and password did not match a user name/password combination in our database. Usernames and passwords are entered in from a different file. Thank you for visiting test login script!!&checklog=2”;  
}  
}  
?\>  
\</body\>  
\</html\>

it suld work but it doesent work can eny 1 help mee
