SA-MP Forums Archive
Help getting something of DB. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help getting something of DB. (/showthread.php?tid=546516)



Help getting something of DB. - xHanks - 15.11.2014

How i get the register IP from database? I use a_mysql.

pawn Код:
case 3:
{
if(response) {
new name[MAX_PLAYER_NAME], solicitud[254];
GetPlayerName(playerid, name, sizeof(name));
format(solicitud, sizeof(solicitud), "SELECT IP FROM usuarios WHERE usuario = '%s'",name);
mysql_query(mysql, solicitud);
new int_dest = cache_get_data();
new string[254];
format(string, sizeof(string), "Tъ IP de registro fue: %s", int_dest);
SendClientMessage(playerid, -1, string);
}