01.03.2018, 02:18
(
Последний раз редактировалось weex; 01.03.2018 в 11:10.
)
Why did i got this error on my mysql.log?
On line:
From:
PHP код:
[02/28/18 19:02:05] [ERROR] cache_get_value_name_int: invalid row index '0' (number of rows: '0') (RP.pwn:4582)
[02/28/18 19:17:45] [ERROR] cache_get_value_name_int: invalid row index '0' (number of rows: '0') (RP.pwn:4582)
PHP код:
cache_get_value_int(0, "UserID", pInfo[playerid][UserID]);
PHP код:
if(dialogid == DIALOG_REGISTER) {
if(!response) return Kick(playerid);
if(response) {
if(!strlen(inputtext)) return ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT, "Please enter a valid password!", "Please enter a valid registration password\nTo continue press Register", "Register", "Quit");
else {
SHA256_PassHash(inputtext, HASH_SENHA, pInfo[playerid][pSenha], 64);
GetPlayerIp(playerid, ip, sizeof(ip));
mysql_format(ConnectMYSQL, query, sizeof(query), "INSERT INTO `accounts` (`Username`, `Senha`, `IP`) VALUES ('%e', '%s', '%s')", GetName(playerid), pInfo[playerid][pSenha], ip);
mysql_query(ConnectMYSQL,query);
//printf("Dialog register MySQL error: %d", mysql_errno(ConnectMYSQL));
pInfo[playerid][Registered] = true;
pInfo[playerid][LoggedIn] = true;
pInfo[playerid][Cadastrando] = true;
Logado[playerid] = 1;
GivePlayerMoneyEx(playerid, 500);
SendClientMessage(playerid, COLOR_GREY, "Registered Sucess!");
cache_get_value_int(0, "UserID", pInfo[playerid][UserID]);
firstlogin[playerid] = true;
OnPlayerLogin(playerid);
SetTimerEx("CheckHack", 3000, 0, "i", playerid);
}
}
return 1;
}