18.12.2011, 08:00
What is wrong in the code?
OK let me explain. First of all when the first printf has been called, the IP[0] is nothing and the IP[1] is my ip address. There is already an ip column on mysql database. So why is that? Secondly and most weirdly, it's printing out STRCOMPARED . How on earth? How did it compared between a string which is nothing with my ip address? I think I have made mistake somewhere.
pawn Код:
new IP[2][16];
mysql_fetch_field_row(IP[0], "ip");
printf("IP[0] is %s and IP[1] is %s", IP[0], IP[1]);
if(!strcmp(IP[0], IP[1]))
{
printf("STRCOMPARED between IP[0] is %s and IP[1] is %s", IP[0], IP[1]);
}