19.07.2016, 09:26
PHP код:
error 035: argument type mismatch (argument 1)
This is the line
PHP код:
UpisiLog(LOG_REGISTER, string);
error 035: argument type mismatch (argument 1)
UpisiLog(LOG_REGISTER, string);
stock UpisiLog(fajl[], string[])
{
new unos[256];
new sat, minut, sekund, dan, mesec, godina;
gettime(sat, minut, sekund);
getdate(godina, mesec, dan);
format(unos, 256, "[%d/%d/%d - %d:%d:%d] %s\r\n", dan, mesec, godina, sat, minut, sekund, string);
new File:hFile;
hFile = fopen(fajl, io_append);
fwrite(hFile, unos);
fclose(hFile);
return 1;
}
#define LOG_REGISTER "Logovi/Registracija.txt"
stock UpisiLog(fajl[],LOG_REGISTER[], string[]) { new unos[256]; new sat, minut, sekund, dan, mesec, godina; gettime(sat, minut, sekund); getdate(godina, mesec, dan); format(unos, 256, "[%d/%d/%d - %d:%d:%d] %s\r\n", dan, mesec, godina, sat, minut, sekund, string); new File:hFile; hFile = fopen(fajl, io_append); fwrite(hFile, unos); fclose(hFile); return 1; }
im not confirmed but just try it.
Код:
stock UpisiLog(fajl[],LOG_REGISTER[], string[]) { new unos[256]; new sat, minut, sekund, dan, mesec, godina; gettime(sat, minut, sekund); getdate(godina, mesec, dan); format(unos, 256, "[%d/%d/%d - %d:%d:%d] %s\r\n", dan, mesec, godina, sat, minut, sekund, string); new File:hFile; hFile = fopen(fajl, io_append); fwrite(hFile, unos); fclose(hFile); return 1; } |