mySQL dialog to register/login help
#3

pawn Код:
//REGISTER
new tmp[128];
new name[24];
GetPlayerName(playerid,name,sizeof name);
format(tmp, sizeof(tmp), "INSERT INTO `users` (`username`, `password`) VALUES ('%s', md5('%s'))", name, inputtext);
mysql_query(tmp);
pawn Код:
//LOGIN
new str[100],name[24];
GetPlayerName(playerid,name,sizeof name);
format(str, sizeof(str), "SELECT * FROM `users` WHERE `username` = '%s' AND `password` = md5('%s')",name,inputtext);
mysql_query(str);
Reply


Messages In This Thread
mySQL dialog to register/login help - by PabloDiCostanzo - 27.08.2013, 22:09
Re: mySQL dialog to register/login help - by cpbarn - 27.08.2013, 23:13
Re: mySQL dialog to register/login help - by zaider - 27.08.2013, 23:16
Re: mySQL dialog to register/login help - by PabloDiCostanzo - 27.08.2013, 23:18
Re: mySQL dialog to register/login help - by zaider - 28.08.2013, 00:12
Re: mySQL dialog to register/login help - by [HiC]TheKiller - 28.08.2013, 00:38
Re: mySQL dialog to register/login help - by [HiC]TheKiller - 28.08.2013, 00:41

Forum Jump:


Users browsing this thread: 3 Guest(s)