Saving problem
#8

In register process example:

pawn Код:
if(!response)
            {
                SendClientMessage(playerid, COLOR_LIGHTRED, "This question is mandatory, come back and fill it in!");
                Kick(playerid);
            }
            else if(strlen(inputtext) < 4 || strlen(inputtext) > 48)
            {
                SendClientMessage(playerid, COLOR_LIGHTRED, "We can't accept your question. It must be longer then 4 characters, but no more then 48.");
                ShowPlayerDialog(playerid, 3, DIALOG_STYLE_INPUT, "Security Question - Step 1", "What would you like your security question to be?", "Submit", "Leave");
            }
            else
            {
                new string[128], esc_inputtext[48];
                format(string, sizeof(string), "You have entered; \"%s\" as your security question. Is this correct?", inputtext);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, string);

                mysql_real_escape_string(inputtext, esc_inputtext);
                format(Query, sizeof(Query), "UPDATE `Accounts` SET `Security Question` = '%s' WHERE `Username` = '%s'", esc_inputtext, GetName(playerid));
                mysql_query(Query);
// here i put and works
pawn Код:
GetPlayerIp(playerid, pStats[playerid][pIPAddress], 17);
        format(Query, sizeof(Query), "UPDATE `Accounts` SET `IP Address` = '%s' WHERE `Username` = '%s'",  pStats[playerid][pIPAddress], GetName(playerid));
        mysql_query(Query); //Queries
pawn Код:
ShowPlayerDialog(playerid, 4, DIALOG_STYLE_LIST, "Security Question - Step 1 (confirmation)", "Yes, continue.\nNo, try again.", "Submit", "Leave");
            }
        }


when i put here, result
pawn Код:
[19:50:10] CMySQLHandler::Query(UPDATE `Accounts` SET `IP Address` = '127.0.0.1' WHERE `Username` = 'Player') - Successfully executed.
Works Good
Reply


Messages In This Thread
Saving problem - by juraska - 16.07.2011, 14:43
Re: Saving problem - by juraska - 16.07.2011, 15:27
Re: Saving problem - by park4bmx - 16.07.2011, 15:47
Re: Saving problem - by juraska - 16.07.2011, 16:06
Re: Saving problem - by park4bmx - 16.07.2011, 16:09
Re: Saving problem - by juraska - 16.07.2011, 16:19
Re: Saving problem - by park4bmx - 16.07.2011, 16:39
Re: Saving problem - by juraska - 16.07.2011, 16:58
Re: Saving problem - by juraska - 16.07.2011, 17:45
Re: Saving problem - by juraska - 17.07.2011, 09:29

Forum Jump:


Users browsing this thread: 3 Guest(s)