Quote:
Originally Posted by [Bios]Marcel
U can insert line breaks like this:
PHP код:
format(string, sizeof(string), "UPDATE `ptp` SET `Admin` = '%d', `Kills` = '%d', `Deaths` = '%d', `Ratio`\
= '%f' ,`HoursPlayed` = '%d', `MinutesPlayed` = '%d', `SecondsPlayed` = '%d', `Score` = '%d', `Cash` =\
'%d' WHERE `username` = '%s'", P_Account[playerid][Admin], P_Account[playerid][Kills], P_Account[playerid][Deaths],\
P_Account[playerid][Ratio], P_Account[playerid][HoursPlayed], P_Account[playerid][MinutesPlayed], \
P_Account[playerid][SecondsPlayed], P_Account[playerid][Score], P_Account[playerid][Cash]);
|
I'm pretty sure these slashes are not needed.
What you can also do is break the string into pieces like this:
Код:
format(string, sizeof(string), "item1 = 1, item2 = 2);
format(string, sizeof(string), %s, item3 = 3, item4 = 4, string);