Hello guys. Im tryingo todo to read .txt file in anywhere. My code:
PHP Code:
stock GetMatchID()
{
new fp = fopen("addons/amxmodx/configs/gunid.txt"), gettheid[100];
while (!foef(fp));
{
new showmatchid = fgets(fp, gettheid, charsmax(gettheid);
return gettheid;
}
fclose(fp)
}
But getting error then compiling. Why i'm using stock? I want to show the ID anywhere where i put %s. Example:
PHP Code:
client_printcolor(0, "Gun ID is now: %s", GetMatchID)